thanks for your help but i figured it out...i was testing a mod_rewrite for apache in php and i figured if i could figure this out in php then it would work in mod_rewrite.
hi,
how do i match anything in the expression other than "certain words".
Say i have bunch of strings like this:
1234.abc.com,
asd.abc.com,
ees.abc.com,
www.abc.com
Now i want to match all the strings that do not have "www." at the start of the string.
For example in the strings above the...
hi,
i am trying to grab some foreign character from an html page and insert it into a mysql database ...
For example say the character was chinese or russian,,,when i view it on a webpage it looks fine but when i try to pass it php script it converts to gibberish,,,what should i do to convert...
hi,
i have this redirect rule which doesnt seem to work for some reason.
I have a directory called "blog" inside which the .htaccess with the rule below exists. For some reason it doesnt work any idea?
RewriteEngine On
RewriteRule ^/(.*)$ ../index.php?base=viewblog
Hi,
I have a script that executes curl on various websites. I also have 5 internal ip for my box.
Is it possible to rotate execute the curl as if it was coming from one of those IP addresses?
I thought the CURLOPT_PROXY was the option but i am not sure if this the correct method.
hi,
i am trying to understand this regex expression and i just want to clarify with the fellow users if my interpretation is right:
(?!(?:#|javascript\s*:))
the first "?" from the left means this is optional. the "!" after that means anything that doesnt match. The code inside the is...
Hi,
I am trying to append an innerHTML that looks like this:
var inn = '<javascript src="/test.js">blah..blah..blah<input type="text">';
When I append the inn to an existing div it works fine in Firefox but fails to even show up in IE....any idea how to get around this.
thanks
ro
Hi,
I have a system where i am trying to pass session between two files.
There is a file called "editor.php" and there is a file called "index.php"
when i am in "editor.php" i set certain session variables. Within that "editor.php" i call php's "file" command like this:
$fh =...
Thanks for all the replies. I ended up using "monksnake" method but another question arose. How do I match nested tags. For example this is the string that I have:
<span name="form1"><input type="text" name="" value=""><input type="checkbox" name="" value=""><span name="form2"><input...
The example below works when there is line break in the string. But how do I modify the regex if there is no linebreak in the string.
var backRefs = new Array();
var testString = '<form name=form1>\n'+
'kajhsdskjadas</form>\n'+
'<form name=form2>\n'+
'aksjashkjashjkas</form>\n'+...
I tried the code below without success. any ideas:
var regex = new RegExp("form name=(.*[^>])","g");
var match = regex.exec("<form name=form1><form name=form2><form name=form3");
if (match == null) {
alert("No match");
} else {
var string...
hi,
I have a string containing html where i need to use regex to match certain elements.
the string can be
ajkshajda
<form name="form1"></form>
aksdhaskjashd
<form name="form2"></form>
lakjdkjasjas
"
how would you match all the <form name=""> elements and get the "name" of the form?
thanks
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.