Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
My code disappear
#1
Why by editing page in <>source section after clicking on "Save Updates" my code disappear? That what I have changed is visible on website but when I back to "edit page" I can't see a code I put few seconds ago. Why?

Sorry for my english.
Reply
#2
What "code" are you putting in?
Sounds like a cache issue.
NEW: SA Admin Toolbar Plugin | View All My Plugins
- Shawn A aka Tablatronix
Reply
#3
HTML part disappear

HTML
PHP Code:
<a href="#" class="greenhead"
onclick="style.background='url(http://i.cubeupload.com/Gi4rVR.png) ' "></a


CSS
PHP Code:
.greenhead {
  
width200px;
  
height200px;
  
displayblock;
  
border0px;
  
backgroundurl('http://i.cubeupload.com/TYeudm.png');
}

.
greenhead:hover {
  
backgroundurl('http://i.cubeupload.com/lYu4hD.png');

Reply
#4
your link is empty, ckeditor will remove empty tags.
NEW: SA Admin Toolbar Plugin | View All My Plugins
- Shawn A aka Tablatronix
Reply
#5
What you mean "empty"? You mean:

1)
<a href="this" class="greenhead"
onclick="style.background='url(http://i.cubeupload.com/Gi4rVR.png) ' "></a>

or

2)
<a href="#" class="greenhead"
onclick="style.background='url(http://i.cubeupload.com/Gi4rVR.png) ' ">this</a>

when i put link insted of hash than mr. greenface display on site but code disappear, exactly as before.

If you mean a second case. I have a lil bit similar code like this one, without css only html:

PHP Code:
<a href="http://www.get-simple.info" rel="newWindow" target="_blank"><img alt="Getsimple" height="200" onclick="this.src='http://i.cubeupload.com/Gi4rVR.png'; this.onmouseover='none'; this.onmouseout='none'" onmouseout="this.src='http://i.cubeupload.com/TYeudm.png'; " onmouseover="this.src='http://i.cubeupload.com/lYu4hD.png'; " src="http://i.cubeupload.com/TYeudm.png" width="200" /></a

And this one don't disappear but as you see it's too long and i need shorter but I don't know what am I supposed to do.

I don't know how first code should look like.
Reply
#6
you cannot use onclick handlers on an image, it should be on the link.

Also you probably want to do all this in a js file, using listeners. Inline js is not really used anymore, also it will seperate your code from your editor nicely.
NEW: SA Admin Toolbar Plugin | View All My Plugins
- Shawn A aka Tablatronix
Reply




Users browsing this thread: 1 Guest(s)