Textpattern Forum

You are not logged in. Register | Login | Help

#21 2012-05-18 17:42:29

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

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

Hello Yiannis

Deleting a script works fine on the several setups I’ve tested it on .. so I can’t reproduce your problem.

What’s your setup (Textpattern version, PHP version, plugin verison)?

And what happens if you edit the script you can’t delete, re-save it and then try to delete it?

Thanks,

Simon

Offline

#22 2012-05-19 05:04:18

colak
Admin
From: Cyprus
Registered: 2004-11-20
Posts: 4,989
Website

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

Hi Simon,

If I edit the script and save it, the static file is recreated. If i delete the script from the txp interface, the static file is deleted but the entry is still visible in the txp interface and the db.

the diagnostics might be of help:

Textpattern version: 4.4.1 (r3575)
Last update: 2012-04-30 08:01:16/2012-04-30 07:56:10
PHP version: 5.3.5
GD Image Library: bundled (2.0.34 compatible); supported formats: GIF, JPG, PNG.
Server TZ: America/Los_Angeles
Server local time: 2012-05-18 21:58:49
DST enabled?: 0
Automatically adjust DST setting?: 0
Time zone: Asia/Nicosia (7200)
MySQL: 5.1.39-log
Locale: en_GB.UTF-8
Server: Apache
PHP server API: cgi-fcgi
RFC 2616 headers: 0
Server OS: Linux 3.2.15-grsec-grsec-2.9-rc1
Active plugins: zem_contact_lang-4.0.3.6, zem_contact_reborn-4.0.3.20, zem_redirect-1.2.1, glx_if-0.7, rss_admin_db_manager-4.3, mem_postmaster-1.0.7, adi_notes-1.1.1, spf_js-0.2, upm_img_popper-1.3.7, rvm_css-0.9.1, wet_babble-0.2, mem_postmaster_library-1.0.4, bot_privs-0.3.2, bot_write_tab_customize-0.7.1, rah_textile_bar-0.7, smd_where_used-0.30, rah_change_passwords-0.8
Admin-side theme: remora 4.4.1

.htaccess file contents: 
------------------------
#DirectoryIndex index.php index.html

#Options +FollowSymLinks
#Options -Indexes
#ErrorDocument 403 default

<IfModule mod_rewrite.c>
	RewriteEngine On
	#RewriteBase /relative/web/path/

	RewriteCond %{REQUEST_FILENAME} -f [OR]
	RewriteCond %{REQUEST_FILENAME} -d
	RewriteRule ^(.+) - [PT,L]

	RewriteCond %{REQUEST_URI} !=/favicon.ico
	RewriteRule ^(.*) index.php

	RewriteCond %{HTTP:Authorization}  !^$
	RewriteRule .* - [E=REMOTE_USER:%{HTTP:Authorization}]
</IfModule>

#php_value register_globals 0

------------------------

Yiannis
——————————
neme.org | neme-imca.org | hblack.net | LABS

Offline

#23 2012-05-19 11:03:51

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

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

Hello Yiannis

The code in the delete function is pretty much the same as that in rvm_css (and txp_css).

Could you please check the following:

- is the problem specific to one script (i.e. can you create, edit and delete a ‘test’ script successfully)?

- can you create, edit and delete stylesheets successfully?

- what’s the name you gave to the script you can’t delete?

Thanks,

Simon

Last edited by spiffin (2012-05-19 15:11:48)

Offline

#24 2012-05-19 11:23:49

colak
Admin
From: Cyprus
Registered: 2004-11-20
Posts: 4,989
Website

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

spiffin wrote:

Hi Simon

- is the problem specific to one script (i.e. can you create, edit and delete a ‘test’ script successfully)?

Yes

- can you create, edit and delete stylesheets successfully?

Yes

- what the name you gave to the script you can’t delete?

You might have something here. The name of the script is jquery.cycle. The dot might be the one which causes problem

Last edited by colak (2012-05-19 11:24:30)


Yiannis
——————————
neme.org | neme-imca.org | hblack.net | LABS

Offline

#25 2012-05-19 13:05:32

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

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

New version 0.3 fixes delete issues with dots in filenames (thanks Yiannis).

Download

(Yiannis: if you re-save your jquery.cycle script – and then try and delete it – it should work.)

Simon

Offline

#26 2012-05-19 15:06:44

colak
Admin
From: Cyprus
Registered: 2004-11-20
Posts: 4,989
Website

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

That was very fast. The new version fixes the problem. Thanks!


Yiannis
——————————
neme.org | neme-imca.org | hblack.net | LABS

Offline

#27 2012-05-28 15:46:07

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

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

Version 0.4 released – now with Minify support.

Offline

#28 2012-06-20 11:44:23

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

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

#@spf_js
#@language it-it
spf_javascript => JavaScript
spf_js_dir => JavaScript directory
spf_script_name => Nome dello script
spf_edit_script => Stai modificando lo script
spf_copy_script => &#8230;o copia lo script con nome
spf_all_scripts => Tutti gli script
spf_create_new_script => Crea nuovo script
spf_script_created => Script <strong>{name}</strong> creato.
spf_script_exists => Lo script <strong>{name}</strong> esiste gi&agrave;.
spf_script_name_required => Per favore inserisci un nome per lo script
spf_script_updated => Script <strong>{name}</strong> aggiornato.
spf_script_deleted => Script <strong>{name}</strong> cancellato.
spf_cannot_delete_default_script => Lo script <strong>default</strong> non pu&ograve; essere cancellato.

Offline

#29 2012-06-20 16:10:54

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

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

MarcoK wrote:

#@language it-it

Thanks Marco – Italian Textpack added.

Offline

#30 2012-07-11 16:50:50

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

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

spiffin a écrit:

Dragondz wrote:

Is the plugin parsed (can we include txp tag inside javascript file) ?

Hi Rabah

The simple answer is no. Textpattern tags (along with PHP) are server-side – and JavaScript is client-side.
This post might help.
Simon

Hi Simon

Ok then the only way to use txp tag inside javascript is to embed the code directly into the page or form, but not on javascript tab.

Offline

Board footer

Powered by FluxBB