FUDforum
Fast Uncompromising Discussions. FUDforum will get your users talking.

Home » Imported messages » comp.lang.php » variable path lose slashs when used in an alert
Show: Today's Messages :: Polls :: Message Navigator
Return to the default flat view Create a new topic Submit Reply
variable path lose slashs when used in an alert [message #177526] Fri, 06 April 2012 15:05 Go to previous message
anver is currently offline  anver
Messages: 5
Registered: November 2010
Karma:
Junior Member
variable $temp is a path
C:\www\site\test\folder\img.jpg

if I write
echo $temp;
ok I have all the path
---------

but if I use same variable in an alert I haven't more the correct path;
haven't the \ slashs

echo"<script type='text/javascript'>";
echo "alert('$temp')";
echo "</script>";

I tested also string but is equal
$temp=(string)$temp;


is there a solution?
[Message index]
 
Read Message
Read Message
Read Message
Previous Topic: variable path lose slashs when used in an alert
Next Topic: PHP5 DOM extension - using firstChild
Goto Forum:
  

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ]

Current Time: Thu Nov 28 18:36:12 GMT 2024

Total time taken to generate the page: 0.03358 seconds