When I paste a code with the tag -
<body onload="">
in a HTML block and the saves it, the tag is gone after saving it.
I have search for it in a lot of files, but I can't find it.
Anyone who knows where it is?
When I paste a code with the tag - <body onload=""> in a HTML block and the saves it, the tag is gone after saving it.
I have search for it in a lot of files, but I can't find it.
Anyone who knows where it is? |
This is one of the tags stipped by TinyMCE via safehtml My opinions expressed on this site, in no way represent those of Boonex or Boonex employees. |
Ok, I got it.
Then it is impossible to use any Google Earth map with some extra stuff.
Thank's |
Not necessarily. D6 would need some modification to allow all html tags by the admin, while still stripping the tags for regular site members. My opinions expressed on this site, in no way represent those of Boonex or Boonex employees. |
Not necessarily. D6 would need some modification to allow all html tags by the admin, while still stripping the tags for regular site members. Just throwing out an idea here. What if we used a 2nd safe.html file, either in the admin directory or right next to the first one and then an if $ownerAdmin true function it allows the extra tags, if $ownerMember true then it doesn't.
I don't have the full function, but that might be the way to go here on this one. |
RE: Just throwing out an idea here. What if we used a 2nd safe.html file, either in the admin directory or right next to the first one and then an if $ownerAdmin true function it allows the extra tags, if $ownerMember true then it doesn't.
I don't have the full function, but that might be the way to go here on this one. Don't know. I've been messing with this one for a while. I can't even get the google map code to work when I paste it directly into the database. All I get is "The Google Maps API server rejected your request. The "sensor" parameter specified in the request must be set to either "true" or "false"." I even tried putting the code between the header tags in _header.html and the rest in the database, and I still got the same error. My opinions expressed on this site, in no way represent those of Boonex or Boonex employees. |
Nah.. Work your head a little more, your close on this...
Just out of curiosity again.. Just because I'm curious check out the admin/JsHttpRequest/JsHttpRequest.php file. There's some interesting stuff sitting in that thing, might guide you to the final solutin here. Especially since it appears to allow different js for Admin than it does the members. |
Naw... somebody that actually knows what they're doing can work on it. It's not a total loss. At least now I have a page with a full screen map of Houston I can look at. I don't have the files you refer to in my D6 installation. My opinions expressed on this site, in no way represent those of Boonex or Boonex employees. |
Naw... somebody that actually knows what they're doing can work on it. It's not a total loss. At least now I have a page with a full screen map of Houston I can look at. That really was your goal the whole time wasn't it Houston... ROFLMAO |
Now I'm confused. I couldn't get Google map code to work in an html block, but the Google Earth code below works just fine... If I first create an html block on a page in page builder, then edit it's contents in the PageCompose table. Too bad I keep getting a strange error when I try to install the Google Earth plugin on my computer> Windows is a POS some times! <html> My opinions expressed on this site, in no way represent those of Boonex or Boonex employees. |
I have tested a lot of Google maps who displays fine in a html block. The thing is that I want to embed a Google Earth map who has some kind of button, (like the original 'Dusk to Dawn').
When such a map is embeded the block with the map only shows 'Loading...'
I have discused it with a 'Google Earth Guru' who briefly surveyed my site, and the he told my that the <body onload="init"> is not caled. |
RE: I have tested a lot of Google maps who displays fine in a html block. The thing is that I want to embed a Google Earth map who has some kind of button, (like the original 'Dusk to Dawn'). When such a map is embeded the block with the map only shows 'Loading...' I have discused it with a 'Google Earth Guru' who briefly surveyed my site, and the he told my that the <body onload="init"> is not caled. If you enter the code in page builder, certain tags are going to be stripped, and I couldn find an easy way to bypass the tag stripping. That's why I suggested entering your html code directly into the database. My opinions expressed on this site, in no way represent those of Boonex or Boonex employees. |
So, if the map is embeded on homepage, where in the database do you belive the <body onload="int"> should be injected? |
So, if the map is embeded on homepage, where in the database do you belive the <body onload="int"> should be injected? If you are using cpanel, use phpmyadmin to open your Dolphin database, then browse through the PageCompose table. You should should see the record for the html block you created. Just edit that record, replace the cocntents of the field that holds the existing code and save it. My opinions expressed on this site, in no way represent those of Boonex or Boonex employees. |
I saved the Google Earth code with the <body onload="init"> in phpMyAdmin and I can see the code is there after saving it, but the <body onload="init"> code is not included in the HTML block. |
If it is stored correctly in the DB, then you might have to delete the files in the /cache directory (except for .htaccess) You may even have to clear your browser's cache. My opinions expressed on this site, in no way represent those of Boonex or Boonex employees. |
I removed the tags 'body' & 'style' from safehtml.php and after that I saved the Google code from phpMyAdmin. I also tested to save it directly from the HTML block. But, there is always something else who removes the line -
<body onload="init()" style="font-family: arial, sans-serif; font-size: 13px; border: 0;">
from the HTML block.
So what's the trick? |
RE: I saved the Google Earth code with the <body onload="init"> in phpMyAdmin and I can see the code is there after saving it, but the <body onload="init"> code is not included in the HTML block. If the code is there when you save it directly in the database, then it WILL be in the HTML block..... unless, of course, you open the HTML block in page puilder and save it.... Then the tags would be stripped again. My opinions expressed on this site, in no way represent those of Boonex or Boonex employees. |
There must be a 'ghosteraser' somewhere else
Ok, the cache is clear and in safehtml.php 'body' & 'style' has been removed.
Code segment looks like this in phpMyAdmin after saving -
{ document.getElementById('sample-ui').innerHTML += html; } <body onload="init()" style="font-family: arial, sans-serif; font-size: 13px; border: 0;">
Code segment looks like this in HTML Block after saving in phpMyAdmin -
{ document.getElementById('sample-ui').innerHTML += html; }
It must be the 'bodysnatchers' |
Can you post the code you are using, or send it to me via PM? My opinions expressed on this site, in no way represent those of Boonex or Boonex employees. |