vangilsweb Posted January 27, 2011 Share Posted January 27, 2011 I have the following variable: $text = "javascript:openimage('http://images.icecat.biz/img/norm/high/5966342-254.jpg',850,850)" Now I want to put the string "http://images.icecat.biz/img/norm/high/5966342-254.jpg" into a variable called $url ( $url = "http://images.icecat.biz/img/norm/high/5966342-254.jpg" ) How do I do this? Quote Link to comment Share on other sites More sharing options...
PaulRyan Posted January 27, 2011 Share Posted January 27, 2011 <?PHP $text = "javascript:openimage('http://images.icecat.biz/img/norm/high/5966342-254.jpg',850,850)"; $url = explode('\'',$text); $url = $url[1]; ?> Try the above and tell me how it goes Regards, PaulRyan. Quote Link to comment Share on other sites More sharing options...
vangilsweb Posted January 27, 2011 Author Share Posted January 27, 2011 YES this works! Thank you very much! Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.