Results 1 to 2 of 2
Jun 28, 2006, 17:40 #1
does anyone know how to insert java into specific items for Nucleus CMS? I don't want it in the header/footer, but I want to add it into specific articles (items)
I saw that someone asked this on the nucleus forum, but they never got a clear answer and that was in 2005!
If anyone happens to use Nucleus and knows, i'd really appreciate it!
Jun 29, 2006, 20:31 #2
Well for anyone interested in the answer to this - it took me 2 days and at least a goojillion google searches , but here's how to make it work:
1. open the BLOG.php file in /nucleus/nucleus/libs
2. refer to this forum post in the Nucleus forum to see how to change BLOG.php to allow PHP includes (hint, you're only changing 1 line of code, so it's not hard!)
3. go to http://www.451press.com/phpadsense.php and download a copy of phpadsense. it's a free script (not mine) and easy to configure. note: the first time I went to this page, I wasn't able to download as the link was down. I went back a few hours later - mainly because I was desperate - and it was working.
4. log into your blog and edit the item in question with: <%phpinclude(/path/to/adsense.php)%>
note - no quotes and you need the direct path to the file, not the URL.
that's it. If you're anal-retentive like me and you insist on having total control over how your page looks and want each blog entry to be individual vs total cookie cutter, then this works.
I know it's a PHP solution for a java problem, but it's the only way I could make it work. if anyone has a better solution (i.e how to do this directly in the article w/o having to refer to an outside script - I'm all for it!)