Jump to content

Is it a bad js-code or something else?


eld

Recommended Posts

Hi! It`s about an user account in an online business directory. There is a problem with the addresses and phone numbers and I`m trying to fix it by putting some js-code along with other info. The admin-page looks like this: http://1drv.ms/1iLThHQ and the public-page is here: aptekizapad.informator.bg (desctop-version) and here: www.informator.bg/cgi-bin/mobile/index.pl?_state=Info&ID=1000117008&br=1 (mobile version). Addresses point to google maps and they not all work very well as I can`t use 2 different strings – the address to display and a string for google maps to search (either the address itself or coordinates). This I managed to fix in desctop-version by replacind address-links using js-code (see page source, row 135). It seems that the same aproach doesn`t work for mobile version. Even an alert doesnt appear there (I used this: <script type="text/javascript"> $(document).ready(function() { alert(); }); </script>). I don`t know if the mobile-version blocks my js somehow or my approach is wrong (there is jquery mobile used in mobile-version if this matters).P.S. I hope I managed to explain as a non-native english speaker. I know what I`m trying to do is not the proper way to fix the problems, but as long as this busines directory keeps their web-site buggy, this is my best idea to something about it. If there is similar topic in the forum, please post a link.

Link to comment
Share on other sites

If you're testing to see if Javascript works, don't use jQuery.

 

Test the alert on its own:

<script type="text/javascript"> alert(1); </script>

There's no way that can't work, which makes me believe jQuery's probably not being included properly.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...