Welcome to Geeklog, Anonymous Saturday, November 30 2024 @ 11:46 am EST

Geeklog Forums

geeklog 1.8.0: how to set an external JavaScript file


Status: offline

::Ben

Forum User
Full Member
Registered: 01/14/05
Posts: 1569
Location:la rochelle, France
For internal file I use
Text Formatted Code

global $_SCRIPTS;    
$_SCRIPTS->setJavaScriptFile('pluginname', '/pluginname/javascript/yourfile.js');


And for an external file Confused:

Ben
I'm available to customise your themes or plugins for your Geeklog CMS
 Quote

Status: offline

Laugh

Site Admin
Admin
Registered: 09/27/05
Posts: 1470
Location:Canada
You got me Oops!

I guess there are some cases where that is necessary.

Add it to the bug tracker.

I guess I will either have to add to the functionality to the current function setJavaScriptFile or create a new one called setExternalJavaScriptFile or something.

Tom

One of the Geeklog Core Developers.
 Quote

Status: offline

suprsidr

Forum User
Full Member
Registered: 12/29/04
Posts: 555
Location:Champaign, Illinois
But you can still return the html in getHeaderCode and getFooterCode
return '<script src="//ajax.googleapis.com/ajax/libs/jquery/1.5.1/jquery.min.js"></script>';

-s
FlashYourWeb and Your Gallery with the E2 XML Media Player for Gallery2 - http://www.flashyourweb.com
 Quote

Status: offline

::Ben

Forum User
Full Member
Registered: 01/14/05
Posts: 1569
Location:la rochelle, France
Tom: I added the feature request.

Wayne: Thanks for the reminder.

Ben
I'm available to customise your themes or plugins for your Geeklog CMS
 Quote

All times are EST. The time is now 11:46 am.

  • Normal Topic
  • Sticky Topic
  • Locked Topic
  • New Post
  • Sticky Topic W/ New Post
  • Locked Topic W/ New Post
  •  View Anonymous Posts
  •  Able to post
  •  Filtered HTML Allowed
  •  Censored Content