Advanced search  

News:

cpg1.5.48 Security release - upgrade mandatory!
The Coppermine development team is releasing a security update for Coppermine in order to counter a recently discovered vulnerability. It is important that all users who run version cpg1.5.46 or older update to this latest version as soon as possible.
[more]

Pages: 1 [2]   Go Down

Author Topic: Custom javascript code to footer  (Read 10867 times)

0 Members and 1 Guest are viewing this topic.

Αndré

  • Administrator
  • Coppermine addict
  • *****
  • Country: de
  • Offline Offline
  • Gender: Male
  • Posts: 15760
Re: Custom javascript code to footer
« Reply #20 on: August 26, 2013, 11:11:45 am »

I haven't noticed any issues yet (have used that approach in some plugins so far).
Logged

mykee

  • Contributor
  • Coppermine frequent poster
  • ***
  • Country: hu
  • Offline Offline
  • Gender: Male
  • Posts: 140
    • One moment from Hungary
Re: Custom javascript code to footer
« Reply #21 on: August 26, 2013, 11:37:29 am »

Ok, here is my plugin latest version.

Try these:
- check in Plugin Manager my Isotope liines. This ok.
- open codebase.php
- find this:
Code: [Select]
if (file_exists("./plugins/isotope/lang/{$CONFIG['lang']}.php")) {
  require "./plugins/isotope/lang/{$CONFIG['lang']}.php";
} else {require "./plugins/isotope/lang/english.php";}
- replace with:
Code: [Select]
require('./plugins/isotope/include/init.inc.php');- go to Plugin Manager, and see Isotope section. You will not see anything from language strings.
Logged
My gallery and demo for AnythingSlider, Photocols and CollagePlus plugin: http://foto.acegem.hu/index.php

mykee

  • Contributor
  • Coppermine frequent poster
  • ***
  • Country: hu
  • Offline Offline
  • Gender: Male
  • Posts: 140
    • One moment from Hungary
Re: Custom javascript code to footer
« Reply #22 on: August 26, 2013, 11:41:01 am »

(I cannot edited my previous post.)
Check global $lang_plugin_isotope in footer functions, like this:

Code: [Select]
function isotope_footer_addons($html) {

global $CONFIG,$ISOTOPESET,$CPG_PHP_SELF,$lang_plugin_isotope;

print_r ($lang_plugin_isotope); exit;
Will not get anything! Like $lang_plugin_isotope is empty.
But this working under this:
Code: [Select]
function isotope_mainpage($matches)
{
 global $CONFIG,$lang_plugin_isotope,$FORBIDDEN_SET,$ISOTOPESET,$lang_meta_album_names,$lang_common,$META_ALBUM_SET, $CPG_PHP_SELF,$matches,$html;
 
print_r ($lang_plugin_isotope); exit;
::)
Logged
My gallery and demo for AnythingSlider, Photocols and CollagePlus plugin: http://foto.acegem.hu/index.php

Αndré

  • Administrator
  • Coppermine addict
  • *****
  • Country: de
  • Offline Offline
  • Gender: Male
  • Posts: 15760
Re: Custom javascript code to footer
« Reply #23 on: August 26, 2013, 11:54:46 am »

If it works as expected in the plugin manager, why do you want to replace it?

It probably doesn't work in the footer as I haven't found where you made that array global.
Logged

mykee

  • Contributor
  • Coppermine frequent poster
  • ***
  • Country: hu
  • Offline Offline
  • Gender: Male
  • Posts: 140
    • One moment from Hungary
Re: Custom javascript code to footer
« Reply #24 on: August 26, 2013, 12:03:54 pm »

My plugin working now correctly, what I uploaded at latest time.
If you not found any bug or error in this, then goes to plugins, if JQuery licenses has enable this.  :)
Logged
My gallery and demo for AnythingSlider, Photocols and CollagePlus plugin: http://foto.acegem.hu/index.php

Αndré

  • Administrator
  • Coppermine addict
  • *****
  • Country: de
  • Offline Offline
  • Gender: Male
  • Posts: 15760
Re: Custom javascript code to footer
« Reply #25 on: August 26, 2013, 12:09:52 pm »

I haven't tested your plugin nor had a closer look at its files. If you think your plugin is ready for public, please start a new thread that describes what your plugin does etc. and attach your plugin file.
Logged
Pages: 1 [2]   Go Up
 

Page created in 0.028 seconds with 20 queries.