Wordpress Themes - WP Forum at BFA

Wordpress Themes - WP Forum at BFA (http://forum.bytesforall.com/index.php)
-   Atahualpa 3 Wordpress theme (http://forum.bytesforall.com/forumdisplay.php?f=2)
-   -   Javascript Problem (http://forum.bytesforall.com/showthread.php?t=15355)

bvimusic Sep 10, 2011 11:43 AM

Javascript Problem
 
I am trying to put a countdown timer on a page in atahualpa.
This is the script I am trying to use:

http://www.dynamicdrive.com/dynamici...lcountdown.htm

I pasted the top part of the code into the "HTML Inserts: Header" section and then the other snippet into a post and it doesn't show up.

Can anyone give me an idea as to what I can do to make this work?

juggledad Sep 10, 2011 12:18 PM

good luck, part of the problem is that Wordpress likes to put a <p> in the text even when you don't want it. I would suggest making this into a plugin if you really need it or looking for an existing plugin

bvimusic Sep 12, 2011 02:42 PM

alright. I don't really have an idea how that is done but I will research it.
Thank you.

bvimusic Sep 12, 2011 02:43 PM

This explains in further detail what is causing the problem.

I am trying to add a javascript countdown to my page.
This should be simple enough but I've been struggling with it for way too many hours to even admit.

So, if I make a test .php page on my server with the script in the <head> tag and run it, it runs fine. When I then create a .js file and place that code in the ATO Theme Options > HTML Inserts: Header, it is returning an error. As a result, I feel like something is breaking between atahualpa and my page.. I don't really know what's happening.

Here is the page I'm working on:
http://www.hoodielife.com/time1.php

This code has a debug mode so I can see that it's a problem with acquiring the date / time from the server.. but this isn't the case when the code is part of the original .php page, only when I move it to a separate .js file.

Can someone please help?

juggledad Sep 12, 2011 03:07 PM

Wordpress is adding extra html to the script causing it not to work. If you want this to work, I suggest you build a plugin to add the functionality or look for another plugin that will add a timer.

This is not a theme issue.

You can try asking the question at WordPress.org

bvimusic Sep 12, 2011 04:25 PM

Alright. I do appreciate the response.
There's no chance I can build a plugin for this, I just don't have the experience to do so... I was reading about it but it's not an option.


All times are GMT -6. The time now is 01:09 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.