...

View Full Version :   Problem



j115
03-26-2010, 06:07 PM
My variable is subject and the value of my variable will be Hello World

Here is my code:

var myEvent = new WoopraEvent("postevent"); // Initialize event and give it a name
myEvent.addProperty("apost","<?php echo $subject; ?>" );
myEvent.fire();

Here is my problem. When I look at the source code when the page loads, this shows.

var myEvent = new WoopraEvent("postevent"); // Initialize event and give it a name
myEvent.addProperty("apost","Hello&nbsp;world" );
myEvent.fire();

How can I make it show the space instead of &nbsp;

Thanks!

DJCMBear
03-26-2010, 06:18 PM
My variable is subject and the value of my variable will be Hello World

Here is my code:

var myEvent = new WoopraEvent("postevent"); // Initialize event and give it a name
myEvent.addProperty("apost","<?php echo $subject; ?>" );
myEvent.fire();

Here is my problem. When I look at the source code when the page loads, this shows.

var myEvent = new WoopraEvent("postevent"); // Initialize event and give it a name
myEvent.addProperty("apost","Hello&nbsp;world" );
myEvent.fire();

How can I make it show the space instead of &nbsp;

Thanks!

Do you have "&nbsp;" in you subject string already or does it just show up?

Rowsdower!
03-26-2010, 06:56 PM
You could try this:

var myEvent = new WoopraEvent("postevent"); // Initialize event and give it a name
myEvent.addProperty("apost","<?php echo html_entity_decode($subject); ?>" );
myEvent.fire();



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum