Textpattern CMS support forum
You are not logged in. Register | Login | Help
- Topics: Active | Unanswered
Bookmarklets?
I read on Textpattern Home page that features bookmarklets: “One-click link adding via toolbar bookmarklet “
I was unable to find this… Is this feature already implemented, or it is planned for a future release? It it is already working, how it works?
Thanks!
webloggin’ from Spain with Textpattern
Offline
Re: Bookmarklets?
Here’s one that will take you directly to the link tab. The link Title (taken from the title and URL of the page you’re at when you click the bookmarklet) should be automatically populated in the form.
Change SITEURL and path to textpattern accordingly:
<a href=“javascript:(window.open(‘http://SITEURL/textpattern/index.php?event=link&step=edit&link=Add&bm=1&linkname=‘escape(document.title)’&url=’+escape(window.location.href),’_blank’,‘width=400,height=490,status=yes,resizable=yes,scrollbars=yes’))”>link</a>
text*
Offline
#3 2004-03-10 17:41:51
- zoe
- New Member
- Registered: 2004-03-10
- Posts: 5
Re: Bookmarklets?
Hi,
I’m not sure this is right for everyone. I couldn’t get Dean’s Link to add the Link, so I modified it slightly. I removed the “&step=edit” piece of his link. Here’s what I’m using and it works for me:
<a href=“javascript:(window.open(‘http://SITEURL/textpattern/index.php?event=link&link=Add&bm=1&linkname=‘escape(document.title)’&url=’+escape(window.location.href),’_blank’,‘width=400,height=490,status=yes,resizable=yes,scrollbars=yes’))”>link</a>
(modified)
Last edited by zoe (2004-03-10 18:00:27)
Offline
Re: Bookmarklets?
I arrive at someplace questionable when I click your link, zoe.
Unless ‘Free Credit Card Gateway’ is published with Textpattern :)
Last edited by .s (2004-03-10 17:50:39)
Offline
Re: Bookmarklets?
Thanks Dean and zoe, it’s working ok for me.
There are more bookmarlets available for writing articles, etc?
webloggin’ from Spain with Textpattern
Offline
#6 2004-03-10 18:01:15
- zoe
- New Member
- Registered: 2004-03-10
- Posts: 5
Re: Bookmarklets?
Thanks for pointing that out. I modified it and verified it would error out instead.
Sorry!
Offline
#7 2004-03-10 20:26:30
- Chris
- Member
- Registered: 2004-02-26
- Posts: 22
Re: Bookmarklets?
This bookmarklet takes you to Content > Write and pastes any selected text into the body with a link beneath it. Tested in Firefox and IE6 on WinXP. Let me know if I’ve mucked up.
“New Article”:javascript:grabtext=document.selection?document.selection.createRange().text:document.getSelection();void(txp_article=window.open(‘http://txp.digiblues.com/textpattern/index.php?event=article&Section=articleStatus=4&publish_now=1&link=Add&bm=0&Title=‘escape(document.title)’&Body=‘escape(grabtext)+escape(‘\r\r’)’%22’escape(document.title)’%22%3A’+escape(window.location.href),’_blank’,‘width=790,height=560,status=no,resizable=no,scrollbars=yes’))
I’d love to know if there are any more options available for creating custom bookmarklets.
Offline
#8 2004-03-10 20:36:02
- Chris
- Member
- Registered: 2004-02-26
- Posts: 22
Re: Bookmarklets?
Aaaargh! that got messed up. The final apostrophe and brackets should be part of the URL and some letters don’t get escaped with a slash.
Please see this text file instead.
Offline
Re: Bookmarklets?
Im having some problems with the article bookmarklet in Safari. For some reason, the article isnt written to the database, even though the page reads “Artcle saved” when I press the submit button.
I edited the bookmarlet to better suit my needs. Can anybody see where I messed up?
Bookmarklet: javascript:x=escape(window.getSelection());window.open(‘http://nis.sarup.dk/textpattern/index.php?event=article&step=Edit&publish_now=1&Section=article&Status=4&link=Add&bm=1&Title=‘escape(document.title)’&Body=’+x,’_blank’,‘width=800,height=600,status=yes,resizable=yes,scrollbars=yes’)
Last edited by nissarup (2004-03-13 10:38:51)
Offline
Re: Bookmarklets?
> nissarup wrote:
> Im having some problems with the article bookmarklet in Safari. For some reason, the article isnt written to the database, even though the page reads “Artcle saved” when I press the submit button.
Are you sure that this is a problem with the bookmarklet?
This sounds like the problem other users had when they upgraded to g1.16 without using the upgrade script. Dean said here :
Those using version g1.15 and older. Version g1.16 requires slight alterations to your database. To make these changes, load http://yoursite/textpattern/_g116update.php in a browser. You can then delete that file
Not sure if that’s the problem, but it’s worth a shot, anyway :)
Last edited by Forcery (2004-03-13 17:14:26)
Offline
Re: Bookmarklets?
I did use the update script, and when I go to the admin page manually there is no problem. The articles I write are saved. Its only when I try to write an article in the pop-up window created with this bookmarklet.
Offline