Textpattern CMS support forum

You are not logged in. Register | Login | Help

#31 2012-07-11 17:54:16

colak
Admin
From: Cyprus
Registered: 2004-11-20
Posts: 7,246
Website

Re: spf_js - JavaScript management - create, edit, delete, export to file

Hi Rabah

I’m wondering if rah_external and spf_javascript could work together for your needs.


Yiannis
——————————
neme.org | hblack.net | LABS | State Machines | Respbublika! | NeMe @ github

Offline

#32 2012-07-12 09:59:45

Dragondz
Moderator
From: Algérie
Registered: 2005-06-12
Posts: 1,308
Website

Re: spf_js - JavaScript management - create, edit, delete, export to file

Hi Yiannis

I make a test: create an spf_js:

var toto = <txp:category />

and create a rah_externat_output named css:

<txp:spf_js />

and then embed it using:

<txp:rah_external_output name=“css”/>

that not worked, the code inserted.

But if using rah_external_output alone and putting a snippet:

<script>
var toto = <txp:category name=“produits”/>
</script>

that works, but the js is embedded in html!

I dont think we can parse txp:tags inside spf_js because it stores the js in a flat file to improve speed load, i think i must continue putting thos kind of code directly inside html.

Cheers

Offline

#33 2012-09-09 06:51:13

colak
Admin
From: Cyprus
Registered: 2004-11-20
Posts: 7,246
Website

Re: spf_js - JavaScript management - create, edit, delete, export to file

Hi Simon

I am trying to install this plugin in a subdomain on txp4.5 but it just does not recognise the js directory.

After installation, I visit the advanced preferences where the existing js directory is not detected.
When I enable the plugin I get a modal window stating internal error "Table 'my_db.prefixspf_js' doesn't exist" and after clicking OK I get I’m sorry. I’m afraid I can’t do that. I think spf_js is no safe operation at this time.

I checked the db and spf_js table is not created.

This is the first time I am installing this plugin in a subdomain. Should you need a login to the site to check what is happening please let me know.

Last edited by colak (2012-09-09 15:26:04)


Yiannis
——————————
neme.org | hblack.net | LABS | State Machines | Respbublika! | NeMe @ github

Offline

#34 2012-09-12 13:56:40

spiffin
Plugin Author
From: London, UK
Registered: 2004-06-08
Posts: 95
Website

Re: spf_js - JavaScript management - create, edit, delete, export to file

Hello Yiannis

I’ve just installed a clean copy of Textpattern 4.5.1 on a local subdomain and installed spf_js with no problems whatsoever.

I’m assuming your site is on a Unix server with PHP 5?

I suggest you check your file privileges, database privileges and check your logs (PHP and MySQL error logs).

Simon

Offline

#35 2012-09-12 14:05:47

colak
Admin
From: Cyprus
Registered: 2004-11-20
Posts: 7,246
Website

Re: spf_js - JavaScript management - create, edit, delete, export to file

hi Simon

It seems that the problem is fixed now. I did not mention that the installation was not only in a subdomain but also in a “prefixed” db. I reinstalled txp without the prefix and your plugin worked just fine.

Having said that, there is a display problem in the remora theme, mentioned here


Yiannis
——————————
neme.org | hblack.net | LABS | State Machines | Respbublika! | NeMe @ github

Offline

#36 2012-09-12 14:10:53

spiffin
Plugin Author
From: London, UK
Registered: 2004-06-08
Posts: 95
Website

Re: spf_js - JavaScript management - create, edit, delete, export to file

Thanks – I’m aware of the styling issues and an update will be coming soon.

I’m away from home until next week so it’ll be a week or two.

Offline

#37 2012-11-03 00:32:38

spiffin
Plugin Author
From: London, UK
Registered: 2004-06-08
Posts: 95
Website

Re: spf_js - JavaScript management - create, edit, delete, export to file

Version 0.5 released for Textpattern >= 4.5.1

Download & info

Offline

#38 2012-11-06 17:58:57

MarcoK
Plugin Author
From: Como
Registered: 2006-10-17
Posts: 248
Website

Re: spf_js - JavaScript management - create, edit, delete, export to file

Hi Simon,

I have a problem with new version: 0.5
I have tried instal into a new TXP installation and the plugin not create the prefs field.
So, it show the default script but not save or alter it and I can’t create a new script.

I solved installing version 0.4 and then update to 0.5.

Offline

#39 2012-11-06 18:16:37

spiffin
Plugin Author
From: London, UK
Registered: 2004-06-08
Posts: 95
Website

Re: spf_js - JavaScript management - create, edit, delete, export to file

MarcoK wrote:

I have tried instal into a new TXP installation and the plugin not create the prefs field.

Hi Marco

Thanks for spotting that .. a new version will be out very soon.

EDIT: fixed version (v0.51) out now.

Simon

Last edited by spiffin (2012-11-07 20:42:44)

Offline

#40 2014-12-01 22:09:02

Derekstaff
Member
Registered: 2014-10-23
Posts: 28

Re: spf_js - JavaScript management - create, edit, delete, export to file

I’m having a difficult time getting spf_js to work on my site. As I’ve mentioned in other threads, this is my first time working with more than bare html and css sites, so forgive me if I’m being a bit dense, missing something obvious.

I’m currently developing on my server in a subdirectory (www.mydomainname.com/test) while I work on the site upgrade. The Textpattern installation/directory is in the “test” subdirectory. When the Github page for the plugin states:

“Create a directory for the static JavaScript files in the root of your textpattern installation. You should make sure that PHP is able to write to that directory.”

That means I would put the “js” directory in the “test” directory, correct? Because, for the purposes of developing this upgrade, “test” is the root, right? Or do I put the “js” directory in the “textpattern” directory within the “test” directory?

When the Github page instructions say:

“Visit the Advanced Preferences (Admin > Preferences > Advanced) and make sure the “JavaScript directory” preference contains the directory you created in step 1 (by default ‘js’). “

That means I would put “www.mydomainname.com/test/js” as the path in the Javascript entry under Advanced Preferences, correct?

Thanks for helping me understand.

Offline

Board footer

Powered by FluxBB