[Proto-Scripty] Creating new lines and bypassing them through escapeHTML

2009-06-13 Thread Kash
Hey Guys, I am using the escapeHTML() string function in the following manner. $('divElement').update( stringInput.escapeHTML() ); Now my stringInput is something like This is a test\nThis should be a new line!!! The \n does not show up as a new line on my HTML page. Was hoping someone could

[Proto-Scripty] Re: Creating new lines and bypassing them through escapeHTML

2009-06-13 Thread T.J. Crowder
Hi, String#escapeHTML doesn't do anything with embedded newlines; it Converts HTML special characters to their entity equivalents. Newlines aren't special HTML characters, they're just whitespace. You can easily do what you want with a String#replace[1]: after = before.replace(/\n/g, br/);

[Proto-Scripty] Re: setOpacity issue

2009-06-13 Thread T.J. Crowder
Very very cool, Rick! -- T.J. :-) On Jun 12, 11:33 pm, Rick Waldron waldron.r...@gmail.com wrote: Geneva Switzerland? It was named after this city. The idea being its a convention between two super powers :) Rick On Fri, Jun 12, 2009 at 5:25 PM, Tobie Langel tobie.lan...@gmail.comwrote:

[Proto-Scripty] Doesn't Function.argumentNames care comments in argument parentheses?

2009-06-13 Thread oogatta
Hi, all. First I have to admit that I'm a type lover, so I always write function definitions like this, == var test = function test ( /*Array*/friendList, /*Number*/index ) { // } == but I noticed, when comments appear in arguments list, Function.argumentNames fails to get

[Proto-Scripty] Re: Doesn't Function.argumentNames care comments in argument parentheses?

2009-06-13 Thread T.J. Crowder
Hi, This problem has already been reported and fixed[1], it's just that the fix isn't in 1.6.0.3. I assume it must be in 1.6.1 RC2, which is the bleeding edge you can download from the website[2] since it was fixed six months ago. [1]

[Proto-Scripty] Re: MySQL - order ID

2009-06-13 Thread WLQ
I've followed your link and tried to build the list as you suggested there. But it gives me. ERRNO: 2 TEXT: Invalid argument supplied for foreach() LOCATION: ..., line 7 http://jsbin.com/elocu/edit Here's a list of problems. (I use database to drive the second sortable too). Now, if you

[Proto-Scripty] Re: Doesn't Function.argumentNames care comments in argument parentheses?

2009-06-13 Thread oogatta
Hi, Thank you for mentioning it, and sorry that I failed the check for repository... I can hardly wait the release! T.J. Crowder wrote: Hi, This problem has already been reported and fixed[1], it's just that the fix isn't in 1.6.0.3. I assume it must be in 1.6.1 RC2, which is the

[Proto-Scripty] Re: MySQL - order ID

2009-06-13 Thread Walter Lee Davis
Yes, mysql_query doesn't return a list, it returns a resource identifier. You have to create the list yourself using a loop and mysql_fetch_object or mysql_fetch_array or one of the other fetchers. Before we go much further, I need to remind you that this is not a PHP list, and that those

[Proto-Scripty] Re: MySQL - order ID

2009-06-13 Thread Walter Lee Davis
What does your HTML look like? Are your list element IDs in the form that Sortable requires? ul id=my_sortable_list li id=someString_1The visible draggable part/li li id=someString_3The visible draggable part/li li id=someString_4The visible draggable part/li /ul Unless your LIs have an ID

[Proto-Scripty] Re: MySQL - order ID

2009-06-13 Thread WLQ
Right! There wasn't any _ just the id, now everything is fine. The problem I'm seeing now is that when I clone an item, it's becoming undraggable until you drop on more item. Basically last dropped item won't move, previous items will start moving. It will also create a space [0] = You'll

[Proto-Scripty] Re: how use fire + bind/curry?

2009-06-13 Thread Miguel Beltran R.
2009/6/11 Miguel Beltran R. yourpa...@gmail.com Hi list Trying to do made more functions generics now I try with fire option. But this not work ('element1').observe('change', function(evt){document.fire.curry(evt.element()).('space:observer');}); ('element1').observe('change',

[Proto-Scripty] Re: how use fire + bind/curry?

2009-06-13 Thread kangax
On Jun 11, 8:00 pm, Miguel Beltran R. yourpa...@gmail.com wrote: Hi list Trying to do made more functions generics now I try with fire option. But this not work ('element1').observe('change', function(evt){document.fire.curry(evt.element()).('space:observer');});

[Proto-Scripty] Re: Creating new lines and bypassing them through escapeHTML

2009-06-13 Thread kangax
On Jun 13, 3:32 am, T.J. Crowder t...@crowdersoftware.com wrote: [...] I don't think browsers ever put a \r before the \n in textareas, but I couldn't swear to it, so if it were me I'd probably hedge my bets and optionally include it:     after = before.escapeHTML().replace(/\r?\n/g, br/);

[Proto-Scripty] AJAX request - select element

2009-06-13 Thread fufolewe
Hi, I have a simple problem which is driving me nuts: I would like to make an AJAX req which returns the whole page - select an element by its ID from the response text and update targetDiv with this element (myDivID). But it doenst work :/ function loadContent(url) { new