|
#1
Jun 8, 2013, 02:50 PM
|
|
[SOLVED] Where to put Advertise Code
Hello all;
I've signed up for InfoLinks and Chitika, and they've both given me code and I was wondering where I should input that code in the "Montezuma Options" editor?
Thanks.
|
#2
Jun 8, 2013, 07:22 PM
|
|
|
367 posts · Oct 2012
Florida
|
|
Try making a sidebar and putting the code there. Remember, with MZ, sidebars can also go in headers and footers.
|
#3
Jun 9, 2013, 04:13 AM
|
|
And how would I go about creating sidebars? And in what CSS file would I put that in?
And again, for the advertisement code, which CSS file do I put it in, and where in that file (the end, the middle, etc.)?
|
#4
Jun 9, 2013, 09:05 AM
|
|
|
|
299 posts · Aug 2010
Santa Monica, CA
|
|
The Montezuma theme already comes with one sidebar defined, called Widget Area ONE. On your web site, it should be displaying along the right side, with a section called Categories, a section called Archives and another section called Links, etc. You can use this sidebar as a test before you dive into creating new/other sidebars.
From your Dashboard, click on Appearance > Widgets.
On the right, you will see an area for Widget Area ONE.
In the middle, you'll see a section called Available Widgets.
Drag a Text widget from Available Widgets over to Widget Area ONE and place it where you want it to appear on your sidebar. A Text widget will allow you paste in arbitrary HTML. Paste in your advertising code in the big field and click the blue Save button. Your advertisement should now appear on your sidebar.
With most advertising code, you usually don't have to monkey around with the CSS files unless there's special formatting you want done.
|
#5
Jun 9, 2013, 09:57 AM
|
|
Thanks for the reply.
I found that help (putting a text widget in the sidebar and putting in the code) but it doesn't work. There's nothing at all on the sidebar.
In the email I got from InfoLinks, it says add the code and "Please copy and paste the following script code into your website HTML pages right before the closing </BODY> HTML tag."
So where in the Montezuma editing process can I put that code in?
|
#6
Jun 9, 2013, 06:33 PM
|
|
|
367 posts · Oct 2012
Florida
|
|
What's the code you want to insert? It should go into a sidebar, unless it has more PHP than what's allowed in the limited php code. If that's the case, you might need a php widget. There are several.
|
#7
Jun 10, 2013, 04:28 AM
|
|
Okay so I went to Montezuma Options > Sub Template > footer.php and put the code right before the last </div>, and still nothing shows up on any page.
The code is :
<script type="text/javascript">
var infolink_pid = 1739021;
var infolink_wsid = 0;
</script>
<script type="text/javascript" src="http://resources.infolinks.com/js/infolinks_main.js"></script>
When I put it into any text, it doesn't appear.
Thanks again guys.
|
#8
Jun 10, 2013, 05:08 AM
|
|
|
367 posts · Oct 2012
Florida
|
|
It should work.
1. Try reloading the page and see if it shows up.
2. Try switching to the twenty 12 theme and see if it works. If not, the problem is with something other than MZ.
|
#9
Jun 10, 2013, 05:52 AM
|
|
|
|
23,765 posts · Mar 2009
OSX 10.11.5 WP 4.x Atahualpa(all) Safari, Firefox, Chrome
|
|
Ignore the following, it was added too early in the morning after a bad night sleep before coffee
That won't work because that is not listed in the 'limited php code'
Add a new sidebar (should be called a widget area) to the footer. Add a text widget to it and put your code in the text widget. You may also have to install the plugin 'exec php'
Last edited by juggledad; Jun 10, 2013 at 06:30 AM.
|
#10
Jun 10, 2013, 06:09 AM
|
|
|
367 posts · Oct 2012
Florida
|
|
Quote:
Originally Posted by juggledad
That won't work because that is not listed in the 'limited php code'
Add a new sidebar (should be called a widget area) to the footer. Add a text widget to it and put your code in the text widget. You may also have to install the plugin 'exec php'
|
Juggledad,
Isn't his code all javascript?
Are you saying that MZ only permits limited javascript code as well as limited php code?
|
#11
Jun 10, 2013, 06:29 AM
|
|
|
|
23,765 posts · Mar 2009
OSX 10.11.5 WP 4.x Atahualpa(all) Safari, Firefox, Chrome
|
|
Sorry, too early in the morning with too little sleep last night. Strike my comments in post #10.
the <script...> is HTML not PHP so it should be fine adding it to the virtual template.
|
|