Page 1 of 2
Problem with javascript on some pages
Posted: Thu Jun 24, 2010 10:57 am
by m4dbra1n
Script URL:
Version of script:
Hosting company:
URL of phpinfo.php:
URL of session_test.php:
What terms did you try when SEARCHING for a solution:
Write your message below:
Hi everybody, I've recently upgraded my 2.1 installation to 2.2, and all went good. I'm even making all the mods again from the start, without problems.
But I'ma having a strange issues with the custom fiels OPTIONS link on the Settings page: if I click on it, nothing happen. In fact I had to modify the custom fields I'm using directly from the php file...
Why is this happening? I have the latest JRE and this happens even with Explorer 7/8 and Firefox 3.6.4/.3. Currently I'm using Chrome Dev 6.0.473.3
With the old 2.1 version, this never happened, even with the old JRE and browsers versions.
HELP!
Thanks in advance

Posted: Thu Jun 24, 2010 2:00 pm
by Klemen
It's a Javascript problem (not Java). The Javascript for options hasn't changed since 2.0 so that shouldn't be a problem. Try clearing your browser cache and re-uploading the hesk_javascript.js file.
If it still doesn't work do this:
1. open hesk MAIN admin page in Firefox
2. in FireFox go to "Tools" > "Error console"
3. click "Clear"
4. in HESK go to settings page and click the Options button
5. in FireFox again go to the Error console and see what messages you get.
Posted: Thu Jun 24, 2010 2:53 pm
by m4dbra1n
That's what give the Error Console:
hesk_customOptions is not defined
http://localhost/hesk/admin/admin_settings.php
But I don't understand what it means, sorry

Posted: Thu Jun 24, 2010 4:57 pm
by Klemen
Did you try clearing your browser cache and re-uploading the hesk_javascript.js file?
Does it work for you in the hesk demo?
http://www.hesk.com/demo/admin/admin_settings.php
Posted: Thu Jun 24, 2010 5:07 pm
by m4dbra1n
Yes, I've used CCleaner to delete all the temporary internet files, cookies, saved forms data, from all the browsers.
From your demo it goes straight, without a problem; on mine not, but ? haven't changed a thing of the code, just adjusted some graphics and reordered some text, that's all.
And those mods are taken from the old files of my 2.1 installation, which worked fine...

Posted: Thu Jun 24, 2010 5:24 pm
by Klemen
Any chance you can give me access to your admin panel?
Posted: Thu Jun 24, 2010 5:32 pm
by m4dbra1n
Sorry Klemen, I'm using it in local with XAMPP
This evening I will install it on my site and gave you username and password to let you check it.
Thanks

Posted: Thu Jun 24, 2010 5:41 pm
by Klemen
In that case tell me if that error is the only one you see in the Error console? Are there any other error messages (even if they seem unrelated to hesk)? Can you post a screenshot of the Error console?
Posted: Thu Jun 24, 2010 5:51 pm
by m4dbra1n
Another error in the settings page: if I click on the TEST LANGUAGE FOLDER link, nothing happen, just like if I click on the OPTION button of the custom fields.
The Error Console of Firefox spit this out:
Error: hesk_testLanguage is not defined
Source file:
http://localhost/hesk/admin/admin_settings.php
Row: 1
Another one not defined: but why?
That's different:
Error: missing ) after argument list
Source file:
http://localhost/hesk/admin/admin_settings.php
Row: 84, Column: 48
Code:
if (d.s_site_url.value=='') {alert('Inserisci l'URL. Assicurati che sia valido (inizia con http:// o https://)'); return false;}

Posted: Thu Jun 24, 2010 5:59 pm
by Klemen
OK, so now I know why it doesn't work
There is an error in the hesk_javascript file that you translated - the single quote in
is breaking Javascript code so none of the Javascript works. Change
to
then clear cache, reload page and it should start working.
Posted: Fri Jun 25, 2010 7:34 am
by m4dbra1n
Klemen wrote:OK, so now I know why it doesn't work
There is an error in the hesk_javascript file that you translated - the single quote in
is breaking Javascript code so none of the Javascript works. Change
to
then clear cache, reload page and it should start working.
Sorry Klemen, I have to correct you, as it's not my fault in translating from english; that's the line you are saying to correct as it's translated by me:
Code: Select all
$hesklang['err_surl']='Inserisci l\'URL. Assicurati che sia valido (inizia con http:// o https://)';
Is it right?
And just to let you know, even deleting my modded admin_settings page and using the original version, gives me the same javascript problems...
Posted: Fri Jun 25, 2010 7:55 am
by m4dbra1n
That's the Error Console from the Dev Tools of Chrome:
And this are the 2 files that I'm currently using, maybe you can give a look to them:
http://just2learn.altervista.org/_alter ... ttings.php
http://just2learn.altervista.org/_alter ... t/text.php
I'm not finding any solution by myself and I don't understand if and where I made some mistakes...
Posted: Fri Jun 25, 2010 9:36 am
by Klemen
It's the ' problem for sure. But it's not the problem in the text.php file, it's the problem in the Javascript.
In admin_settings.php try changing
to
Code: Select all
addslashes($hesklang['err_hurl']);
to fix it on-the-fly.
Posted: Fri Jun 25, 2010 9:52 am
by m4dbra1n
Even with your suggested mod, the problem remains, even if I delete all the temp fiels, cookies, etc from both Firefox and Chrome...
Between this evening and tomorrow I will try to made a fresh install with my modded pages and see on my site if that happens anyway...
Posted: Fri Jun 25, 2010 9:55 am
by Klemen
Then I will really need access to your (working) help desk to be able to help.