Simple Machines Community Forum

Customizing SMF => Modifications and Packages => Topic started by: Leipe Po on May 22, 2006, 11:48:26 PM

Title: Bookmark Mod
Post by: Leipe Po on May 22, 2006, 11:48:26 PM
Link to Mod (http://mods.simplemachines.org/index.php?mod=350)

This modification gives you the ability to Bookmark topics,
witch would be very usefull for quick lookups, it uses javascript alerts to tell the user what happends, so they stay on the same page, instead of needing to go back to the topic,

its also detects deleted topics, and auto prune them, giving the users that has a bookmark of the topic a alert that
some topics were auto deleted cause they don't exists anymore,

users will also have the option to choose it as a normal link(witch opens in same window) or choose to open it in a new window, and offcource delete it

Title: Re: Bookmark Mod
Post by: onijin on May 22, 2006, 11:52:54 PM
intresting...

There were a lot of requests for this one... I'll be sure to test it out...

Thanx~   ^_^
Title: Re: Bookmark Mod
Post by: Leipe Po on May 23, 2006, 02:14:04 AM
no problem, if encountered any problem, please let me know so i can fix it!!!,
thanks for the interest of using my product!!!

Leipe_Po
Title: Re: Bookmark Mod
Post by: Leipe Po on May 23, 2006, 03:24:06 AM
update to 1.1 as soon as possible,

some language lines were accidentally left out of the 1.0 package,
i reccommend updating as soon as possible,
my greatest apologies!!!

Leipe_Po
Title: Re: Bookmark Mod
Post by: sbarnes on May 23, 2006, 04:03:41 AM
What a great mod, works really well apart from one main problem on my setup. Not sure if this a problem with the mod or a conflict with one of many other mods.

When I add a topic to the bookmarks, it adds the first post and also all replies to that post. So for a topic that has say 20 replies, I get the first post plus 20 RE: the first posts in the bookmarks.

If I can get that sorted I would be very pleased. Any ideas?
Title: Re: Bookmark Mod
Post by: Leipe Po on May 23, 2006, 04:08:37 AM
could you post a screenshot of what happend?
sorry i don't understand quite as well what your meaning is, also witch version are you using, just release 1.1 cause i overlooked some language lines  :-[

sorry, my apologies

edit:
i registered to your site, dont see the bookmark mod?
Title: Re: Bookmark Mod
Post by: Leipe Po on May 23, 2006, 04:34:30 AM
finded the bug, for a quick fix:

delete any version before 1.2, install 1.2 or higher(when available)!!
Title: Re: Bookmark Mod
Post by: Tony Reid on May 23, 2006, 04:40:37 AM
This doesnt appear to be available in the classic theme (index.template.php) - so Im guessing it wont install easily on others that are based off it?

<![CDATA[ if (in_array($context['current_action'], array('search', 'admin', 'calendar', 'profile', 'mlist', 'register', 'login', 'help', 'pm')))
$current_action = $context['current_action'];
  ]]>
Title: Re: Bookmark Mod
Post by: Leipe Po on May 23, 2006, 10:02:35 AM
Quote from: Tony on May 23, 2006, 04:40:37 AM
This doesnt appear to be available in the classic theme (index.template.php) - so Im guessing it wont install easily on others that are based off it?

<![CDATA[ if (in_array($context['current_action'], array('search', 'admin', 'calendar', 'profile', 'mlist', 'register', 'login', 'help', 'pm')))
$current_action = $context['current_action'];
  ]]>


nope, currently it only supports the default theme, will look into multi theme support once 1.1 final is there,
if you feel like adding support for it, feel free to..

Leipe Po
Title: Re: Bookmark Mod
Post by: sbarnes on May 23, 2006, 10:16:29 AM
Just installed 1.2, works a treat.

Please feel free to try it out with the login you created.

everyone else can try it using login: username: test password:testtest

<Edit: website would help; www.pick-your-brains.co.uk>
Title: Re: Bookmark Mod
Post by: K_4_kelly on May 24, 2006, 06:21:22 AM
 :)

i tried to install
but it got the errors as below:

Execute Modification ./Themes/default/index.template.php Test failed
Execute Modification ./index.php Test failed

anyone help?

thanks!
Title: Re: Bookmark Mod
Post by: Leipe Po on May 24, 2006, 06:39:10 AM
what is the forum version you are using, this one only works for 1.1RC2,
also if those files are modified it could be a problem, but i would be glad to help,


Leipe Po
Title: Re: Bookmark Mod
Post by: K_4_kelly on May 24, 2006, 06:44:44 AM
Quote from: Leipe Po on May 24, 2006, 06:39:10 AM
what is the forum version you are using, this one only works for 1.1RC2,
also if those files are modified it could be a problem, but i would be glad to help,


Leipe Po

thanks for your reply.
i m using 1.1rc2, i didnt modify anything of the 1.1rc beside installed mods
any idea?

thanks!
Title: Re: Bookmark Mod
Post by: Leipe Po on May 24, 2006, 10:10:33 AM
hmmzzz,
no problems on my local testing server with the package downloaded from here(on a clean smf install),
you can also mod the files by hand, if the install doesnt succeed,

there can be several issues with the installation, one of witch could be that some mods modifyed the code the bookmark mod uses, witch will result in a failure, the onley option then is install by hand...
can you post a link to your site?
Title: Re: Bookmark Mod
Post by: qureshi on May 24, 2006, 01:56:49 PM
Hi Leipe Po!

Great work,

But one thing, whenever I access My Bookmarks, this error comes up in the error log:

2: Invalid argument supplied for foreach()
File: /XXXXXXl/smf/Themes/default/Bookmark.template.php (eval?)
Line: 21

How do I fix this?

Nadeem
Title: Re: Bookmark Mod
Post by: qureshi on May 24, 2006, 02:08:44 PM
Hi again,

Ok, I think I figured it out.

When a person has 0 bookmarks, the variable $context['bookmarks'] becomes empty. Thus, we have no index, which makes the argument invalid.

So, one line before:
foreach($context['bookmarks'] as $bookmarks){

Paste:
If ( !empty($context['bookmarks'])){

And on line 85: put an } sign.

Nadeem
Title: Re: Bookmark Mod
Post by: ikbenivo on May 24, 2006, 02:56:35 PM
great mod! Thanks!
Title: Re: Bookmark Mod
Post by: Harzem on May 24, 2006, 03:32:42 PM
If ( isset($context['bookmarks'])){

would be better.
Title: Re: Bookmark Mod
Post by: Leipe Po on May 24, 2006, 03:47:25 PM
this will be corrected in version 1.3 allong with some new stuff!
!empty or isset is more of a coding style then a matter of preformance, they will both return the same result, i prefer something like harzem posted,
but !empty works just as well  ;)
Title: Re: Bookmark Mod
Post by: Harzem on May 24, 2006, 04:04:09 PM
I think "isset" controls whether it is set or not. "empty" first controls whether is is set or not, but if it is set, it checks its value whether it is Null or not. So, when the variable is really set, empty does two checks but isset does one check.

I don't remember where I've read this, but this statement is somewhere deep in my mind :-\

edit:

Example 1. A simple empty() / isset()  comparison.

$var = 0;

// Evaluates to true because $var is empty
if (empty($var)) {
   echo '$var is either 0, empty, or not set at all';
}

// Evaluates as true because $var is set
if (isset($var)) {
   echo '$var is set even though it is empty';
}


http://www.php.net/manual/en/function.empty.php
Title: Re: Bookmark Mod
Post by: RoarinRow on May 27, 2006, 09:46:25 PM
Quote from: ukwalker on May 24, 2006, 06:21:22 AM
:)

i tried to install
but it got the errors as below:

Execute Modification ./Themes/default/index.template.php Test failed
Execute Modification ./index.php Test failed

anyone help?

thanks!


I got these same errors on my 1.1 RC2-1 forum.  Cool concepts thou.   8)
Title: Re: Bookmark Mod
Post by: ltdeta on June 02, 2006, 04:08:48 AM
any chance to get it work for SMF 1.0.7 ?
Title: Re: Bookmark Mod
Post by: CeZa on June 08, 2006, 09:33:43 PM
hi friend

But one thing, whenever I access My Bookmarks, this error comes up in the error log:

/index.php?action=Bookmarks
2: Invalid argument supplied for foreach()
File: /XXXXXXl/smf/Themes/default/Bookmark.template.php (eval?)
Line: 21

How do I fix this? ::)
Title: Re: Bookmark Mod
Post by: geezmo on June 12, 2006, 12:22:17 PM
Where do I edit the name "My Bookmark's" ? It should be "My Bookmarks" without the apostrophe :)

Nice mod though!
Title: Re: Bookmark Mod
Post by: winrules on June 12, 2006, 06:59:56 PM
Great Mod, one suggestion: Could you not echo the alerts in the source file, as that way they will end up before the doc type which will screw up the font size in some browsers.
Title: Re: Bookmark Mod
Post by: ltdeta on June 13, 2006, 03:12:15 AM
Quote from: ltdeta on June 02, 2006, 04:08:48 AM
any chance to get it work for SMF 1.0.7 ?


no answer ?
Title: Re: Bookmark Mod
Post by: Harzem on June 13, 2006, 06:01:36 AM
Quote from: ltdeta on June 02, 2006, 04:08:48 AM
any chance to get it work for SMF 1.0.7 ?

Probably not, Itdeta.
Title: Re: Bookmark Mod
Post by: ltdeta on June 22, 2006, 06:09:47 AM
thanks  :)
Title: Re: Bookmark Mod
Post by: Rumko on June 25, 2006, 11:13:25 AM
Are there any plans for the 1.3 version? Or at least a 1.2.1 version? So that at least the "my bookmark's" and that forgotten "if (isset(..." are fixed?
Title: Re: Bookmark Mod
Post by: PrizeLive.com on June 29, 2006, 02:54:54 PM
Installations actions for "Bookmark Mod By Leipe Po":
Installing this package will perform the following actions:
   Type    Action    Description
1.    Execute Modification    ./Sources/Display.php    Test successful
2.    Execute Modification    ./Themes/default/Display.template.php    Test successful
3.    Execute Modification    ./Themes/default/index.template.php    Test failed
4.    Execute Modification    ./index.php    Test failed
5.    Execute Modification    ./Themes/default/languages/index.english.php    Test successful
6.    Extract File    ./Sources/Bookmark.php    
7.    Extract File    ./Themes/default/Bookmark.template.php    
8.    Execute Code    create_table.php

What can I do to fix this?
Title: Re: Bookmark Mod
Post by: geezmo on June 29, 2006, 07:04:40 PM
Manually add the codes to templates where the installation failed.
Title: Re: Bookmark Mod
Post by: PrizeLive.com on June 30, 2006, 09:24:42 AM
thanks, i'll try it out soon.
Title: Re: Bookmark Mod
Post by: PrizeLive.com on July 19, 2006, 11:59:03 AM
Quote from: Leipe Po on May 24, 2006, 03:47:25 PM
this will be corrected in version 1.3 allong with some new stuff!
!empty or isset is more of a coding style then a matter of preformance, they will both return the same result, i prefer something like harzem posted,
but !empty works just as well  ;)

How's this version coming?
Title: Re: Bookmark Mod
Post by: jdougher on August 03, 2006, 03:34:14 PM
Can you make this mod compatible with 1.0.7?
Title: Re: Bookmark Mod
Post by: absolon on August 03, 2006, 03:45:56 PM
Until it works only with Default Theme is unusefull for me. :(
t's shame.
Title: Re: Bookmark Mod
Post by: Harzem on August 03, 2006, 04:39:49 PM
Many mods MUST only work with default theme. It is not a shame. If you want another theme to use with this mod, you should manually apply it.
Title: Re: Bookmark Mod
Post by: mark25 on August 07, 2006, 10:42:38 AM
the two works fine... but will i use

If ( !empty($context['bookmarks'])){

or

If ( isset($context['bookmarks'])){
Title: Re: Bookmark Mod
Post by: StarBuG on August 07, 2006, 12:53:30 PM
Can someone make some screenshots?

I am not sure if I want to try this hack before I know how it looks

Thank you

StarBuG
Title: Re: Bookmark Mod
Post by: ikbenivo on August 08, 2006, 08:24:27 AM
Here you go.
(In dutch, I've translated the language stuff, the rest is the same)

(http://www.mchob.nl/temp/bookmark1.gif)

(http://www.mchob.nl/temp/bookmark2.gif)
Title: Re: Bookmark Mod
Post by: computer guy on August 14, 2006, 12:06:09 AM
Did anyone ever figure out how to remove the apostrophe from "My Bookmark's" in the forum toolbar?  I like this mod but that drives me crazy!

Running 1.1 RC2
Title: Re: Bookmark Mod
Post by: asdboard on August 27, 2006, 06:28:35 PM
I have a little problem with this mod. Whenever I empty the bookmarks list, I get redirected to the bookmarks page (and this is not strange), but it shows up with oversized font. Clicking on any link sets everything back to the right font size. Suggestions, anyone?
Title: Re: Bookmark Mod
Post by: RoarinRow on September 16, 2006, 05:14:29 PM
Will this be available for RC3?   :D
Title: Re: Bookmark Mod
Post by: codenut on September 16, 2006, 06:42:54 PM
any chance that I might get a bit of help getting the mode to work in a theme that uses graphic buttons

the code in Display.Template.php for adding the Bookmark item is


'bookmark' => array('test' => 'can_reply', 'image' => 'print.gif', 'text' => 'bookmark', 'lang' => true, 'url' => $scripturl . '?topic=' . $context['current_topic'] . '.0;do=Bookmark'),


one of the themes I am trying to add this to uses graphic buttons (which I have made - or make as I go) but I cannot figure how it would get inserted.


$buttonArray = array();
if ($context['can_reply'])
$buttonArray[] = '<a href="' . $scripturl . '?action=post;topic=' . $context['current_topic'] . '.' . $context['start'] . ';num_replies=' . $context['num_replies'] . '">' . ($settings['use_image_buttons'] ? '<img src="' . $settings['images_url'] . '/' . $context['user']['language'] . '/reply.gif" alt="' . $txt[146] . '" border="0" />' : $txt[146]) . '</a>';

if ($context['can_mark_notify'])
$buttonArray[] = '<a href="' . $scripturl . '?action=notify;sa=' . ($context['is_marked_notify'] ? 'off' : 'on') . ';topic=' . $context['current_topic'] . '.' . $context['start'] . ';sesc=' . $context['session_id'] . '" onclick="return confirm(\'' . ($context['is_marked_notify'] ? $txt['notification_disable_topic'] : $txt['notification_enable_topic']) . '\');">' . ($settings['use_image_buttons'] ? '<img src="' . $settings['images_url'] . '/' . $context['user']['language'] . '/notify.gif" alt="' . $txt[131] . '" border="0" />' : $txt[131]) . '</a>';


I am primarily an asp.net guy so my php skills are what you might call sevrely lacking (but working on improving) so hence my request for help.
Title: Re: Bookmark Mod
Post by: GetRank on September 29, 2006, 07:29:49 PM
useful mod
waiting for RC3 version  ;)
Title: Re: Bookmark Mod
Post by: ArkServer on October 01, 2006, 06:52:37 PM
Quote from: Toma-HawK on September 29, 2006, 07:29:49 PM
useful mod
waiting for RC3 version  ;)

Same here, this mod is very usefull.
Title: Re: Bookmark Mod
Post by: Garry1953 on October 01, 2006, 07:56:27 PM
I just installed it on RC3.
Its working fine.
I had to add the Bookmark button manually, as my forum is heavilly modified.

Endeavour Art Studio (http://www.gpurcell.com/artist/ArtForum/index.php)
Title: Re: Bookmark Mod
Post by: GetRank on October 06, 2006, 10:07:22 PM
installed to "new forum" (rc3)
but getting this error

2: Invalid argument supplied for foreach()
File : /************/forum/Themes/default/Bookmark.template.php (eval?)
Line: 21


line21: foreach($context['bookmarks'] as $bookmarks){

uninstall the mod and waiting for rc3 version (or a solution)
this mod in my favorite 5 mods  ;)
Title: Re: Bookmark Mod
Post by: fiver on October 09, 2006, 08:12:40 AM
I have followed the suggestions here, made the changes, packaged it up and it works fine on my 1.1rc3 forum.

Also corrected the spelling mistakes and calm down the '!!!' in warning messages with '.' instead.

I'd like to share it with those interested, but I can't attach the files here, is it possible to submit as an updated mod here?

:)
Title: Re: Bookmark Mod
Post by: Skipdawg on October 09, 2006, 01:00:38 PM
Contact the author Leipe Po about update info.
Title: Re: Bookmark Mod
Post by: RoarinRow on October 09, 2006, 02:21:30 PM
Quote from: fivearts on October 09, 2006, 08:12:40 AM
I have followed the suggestions here, made the changes, packaged it up and it works fine on my 1.1rc3 forum.

Also corrected the spelling mistakes and calm down the '!!!' in warning messages with '.' instead.

I'd like to share it with those interested, but I can't attach the files here, is it possible to submit as an updated mod here?

:)

While we're waiting is it possible to just point out what files you modified and the lines to look for and update?   ;)
Title: Re: Bookmark Mod
Post by: GetRank on October 09, 2006, 07:28:10 PM
Quote from: fivearts on October 09, 2006, 08:12:40 AM
I have followed the suggestions here, made the changes, packaged it up and it works fine on my 1.1rc3 forum.

Also corrected the spelling mistakes and calm down the '!!!' in warning messages with '.' instead.

I'd like to share it with those interested, but I can't attach the files here, is it possible to submit as an updated mod here?

:)

great news

Quote from: RoarinRow on October 09, 2006, 02:21:30 PM
While we're waiting is it possible to just point out what files you modified and the lines to look for and update?   ;)

sure,  want to look over  :D
Title: Re: Bookmark Mod
Post by: fiver on October 12, 2006, 02:15:34 AM
I will put a temporary link here for a week. I am using it on smf1.1rc3 only.

Download it to your pc and upload/install through Admin > Packages > Download Packages > [Choose...] > [Upload]

[edit: link removed]
Title: Re: Bookmark Mod
Post by: MarkoWeb on October 22, 2006, 09:57:34 AM
Can you make this mod compatible with 1.0.8?
Title: Re: Bookmark Mod
Post by: Xarcell on November 04, 2006, 08:44:49 PM
Any chance you can make this work as a Tiny Portal module?
Title: Re: Bookmark Mod
Post by: Gobo on November 08, 2006, 01:05:59 AM
lol seems the 2 of us are out mod hunting

im gona try and install this on my test site and see how it goes
Title: Re: Bookmark Mod
Post by: RoarinRow on November 09, 2006, 12:17:07 AM
Quote from: Xarcell on November 04, 2006, 08:44:49 PM
Any chance you can make this work as a Tiny Portal module?

I'd like it for TP as well please   :)
Title: Re: Bookmark Mod
Post by: Rahya on November 13, 2006, 07:41:53 PM
Hello Leipe ;-)

greetings from germany woman who is married with an netherlands :)

I filled in all of the changes manually who must be made for running the bookmark-mod... but there's one thing I doesn't find, so i could not change it :(
Can you help me?

This should be replaced in Display.template.php:

$normal_buttons = array(
'reply' => array('test' => 'can_reply', 'text' => 146, 'image' => 'reply.gif', 'lang' => true, 'url' => $scripturl . '?action=post;topic=' . $context['current_topic'] . '.' . $context['start'] . ';num_replies=' . $context['num_replies']),
[b]'bookmark' => array('test' => 'can_reply', 'image' => 'print.gif', 'text' => 'bookmark', 'lang' => true, 'url' => $scripturl . '?topic=' . $context['current_topic'] . '.0;do=Bookmark'),[/b] (this line has to be filled in!!)
'notify' => array('test' => 'can_mark_notify', 'text' => 125, 'image' => 'notify.gif', 'lang' => true, 'custom' => 'onclick="return confirm(\'' . ($context['is_marked_notify'] ? $txt['notification_disable_topic'] : $txt['notification_enable_topic']) . '\');"', 'url' => $scripturl . '?action=notify;sa=' . ($context['is_marked_notify'] ? 'off' : 'on') . ';topic=' . $context['current_topic'] . '.' . $context['start'] . ';sesc=' . $context['session_id']),
'custom' => array(),
'send' => array('test' => 'can_send_topic', 'text' => 707, 'image' => 'sendtopic.gif', 'lang' => true, 'url' => $scripturl . '?action=sendtopic;topic=' . $context['current_topic'] . '.0'),
'print' => array('text' => 465, 'image' => 'print.gif', 'lang' => true, 'custom' => 'target="_blank"', 'url' => $scripturl . '?action=printpage;topic=' . $context['current_topic'] . '.0'),
);


because the structure of my template is:
function theme_show_main_buttons()
{
global $context, $settings, $options, $txt, $scripturl;

$buttonArray = array();
if ($context['can_reply'])
$buttonArray[] = '<a href="' . $scripturl . '?action=post;topic=' . $context['current_topic'] . '.' . $context['start'] . ';num_replies=' . $context['num_replies'] . '">' . ($settings['use_image_buttons'] ? '<img src="' . $settings['images_url'] . '/' . $context['user']['language'] . '/reply.gif" alt="' . $txt[146] . '" border="0" />' : $txt[146]) . '</a>';
if ($context['can_add_poll'])
$buttonArray[] = '<a href="' . $scripturl . '?action=editpoll;add;topic=' . $context['current_topic'] . '.' . $context['start'] . ';sesc=' . $context['session_id'] . '">' . ($settings['use_image_buttons'] ? '<img src="' . $settings['images_url'] . '/' . $context['user']['language'] . '/addpoll.gif" alt="' . $txt['add_poll'] . '" border="0" />' : $txt['add_poll']) . '</a>';
if ($context['can_mark_notify'])
$buttonArray[] = '<a href="' . $scripturl . '?action=notify;sa=' . ($context['is_marked_notify'] ? 'off' : 'on') . ';topic=' . $context['current_topic'] . '.' . $context['start'] . ';sesc=' . $context['session_id'] . '" onclick="return confirm(\'' . ($context['is_marked_notify'] ? $txt['notification_disable_topic'] : $txt['notification_enable_topic']) . '\');">' . ($settings['use_image_buttons'] ? '<img src="' . $settings['images_url'] . '/' . $context['user']['language'] . '/notify.gif" alt="' . $txt[131] . '" border="0" />' : $txt[131]) . '</a>';
if ($context['can_send_topic'])
$buttonArray[] = '<a href="' . $scripturl . '?action=sendtopic;topic=' . $context['current_topic'] . '.0">' . ($settings['use_image_buttons'] ? '<img src="' . $settings['images_url'] . '/' . $context['user']['language'] . '/sendtopic.gif" alt="' . $txt[707] . '" border="0" />' : $txt[707]) . '</a>';
$buttonArray[] = '<a href="' . $scripturl . '?action=printpage;topic=' . $context['current_topic'] . '.0" target="_blank">' . ($settings['use_image_buttons'] ? '<img src="' . $settings['images_url'] . '/' . $context['user']['language'] . '/print.gif" alt="' . $txt[465] . '" border="0" />' : $txt[465]) . '</a>';

return implode($context['menu_separator'], $buttonArray);
}


So i could not replace it, because it's other code...

I think that's the reason why I could not see the Button/Link in the themes to "add" to Bookmarks.
The Bookmarks-Button is on the startpage an when I get on it, I see an empty list (must be filled)  ;)
Because for this I need the button/link in themes to add to Bookmarks...

Greetings,
Rahya
Title: Re: Bookmark Mod
Post by: Xarcell on November 17, 2006, 10:22:06 PM
@ Rahya

Your not looking at the right section of code.

You need to add:

'bookmark' => array('test' => 'can_reply', 'image' => 'print.gif', 'text' => 'bookmark', 'lang' => true, 'url' => $scripturl . '?topic=' . $context['current_topic'] . '.0;do=Bookmark'),


After:

'reply' => array('test' => 'can_reply', 'text' => 146, 'image' => 'reply.gif', 'lang' => true, 'url' => $scripturl . '?action=post;topic=' . $context['current_topic'] . '.' . $context['start'] . ';num_replies=' . $context['num_replies']),


in that section of code. You need to find the right section of code. Around line 178, or near about 20% of the way down the page.

Title: Re: Bookmark Mod
Post by: Sam_Gordon on November 20, 2006, 07:28:48 PM
Quote from: fivearts on October 12, 2006, 02:15:34 AM
I will put a temporary link here for a week. I am using it on smf1.1rc3 only.

Download it to your pc and upload/install through Admin > Packages > Download Packages > [Choose...] > [Upload]

[edit: link removed]

Once again, please...  :)
Title: Re: Bookmark Mod
Post by: adp on November 24, 2006, 07:39:11 AM
where i can find the link to my bookmarks list after install?  :-X
Title: Re: Bookmark Mod
Post by: Rahya on November 26, 2006, 03:13:20 PM
did this changings in the default-dir in Display.template.php, but the button "add to favorites" doesn't shown :(((

In the Display.template.php from my otherstyle-dir, there's not the code to replace for, this code I've shown in my posting before... look down...

Don't know why this doesn't work, I've missed only the "add-to-bookmark" button in themes/boards, others work...
Title: Bookmark Mod doesn't work with SMF 1.1
Post by: bambi on December 05, 2006, 10:28:22 AM
Bookmark Mod By Leipe Po 1,2 doesn't work with SMF 1.1

Some idea?
Title: Re: Bookmark Mod doesn't work with SMF 1.1
Post by: vbgamer45 on December 05, 2006, 04:11:24 PM
Try to contact the mod author and see if they will update the mod.
Title: Re: Bookmark Mod doesn't work with SMF 1.1
Post by: bambi on December 08, 2006, 01:40:56 AM
Quote from: vbgamer45 on December 05, 2006, 04:11:24 PM
Try to contact the mod author and see if they will update the mod.

Mmmm....Leipe Po (http://www.simplemachines.org/community/index.php?action=profile;u=12988)   Last Active:   November 04, 2006, 13:28:35
Title: Re: Bookmark Mod
Post by: mgillespie on December 26, 2006, 12:59:12 PM
Any news on this? This is a really neat mod, and not having it for 1.1.1 is a problem for me, means I cannot update my forum software until this happens.

Seems the original author is not around that often, looking at the licence, it appears, as long as I upload any modded version here, and it benefits SMF, then we are free to do so.

I have modified Bookmark 1.2 to work with SMF 1.1.1 (ONLY this version).  I have re-labelled it 1.3.  Hopefully the original author is OK with this.

As usual this comes with no warranties, but it worked a treat on my SMF 1.1.1 installation, and the changes required should not have broken anything (whitespace tabulation has changed in the search criterea).

I have attached the mod, I hope it helps out others..  SMF seriously needs a thread bookmarker, and this is a very good implementation...
Title: Re: Bookmark Mod
Post by: bambi on December 26, 2006, 02:49:41 PM
   
Install mod.
You must ignore warnings, and continue with the installation.

Finally, you will introduce modifications in the following files.

default\Display.template.php
Search:

//SHOW THE LINKTREE:

Add below
//this is for the messages of the bookmarks:
        if(isset($context['bookmark_message']))
                echo $context['bookmark_message'];

index.php
Search:
'.xml' => array('News.php', 'ShowXmlFeed'),
Add below
'Bookmarks' => array('Bookmark.php', 'ShowBookmarks'),

You can test it in my site: 
User: test
Password: test
Title: Re: Bookmark Mod
Post by: Gobo on December 26, 2006, 04:19:49 PM
thanks - I tested on ur site - works perfectly,
ill attempt install now on my forum too :D

EXCELLENT - works perfectly thanks for the 1.1.1 package mgillespie
Title: Re: Bookmark Mod
Post by: Garry1953 on December 26, 2006, 05:00:03 PM
The only Error I had, was for the index.template.php
(It only needed the Button to be added in the array settings)

All other parts installed fine. (No need to modify the code in Display.template.php or index.php)

Thanks

My site below, if anyone wants to check it out  ;D
http://artforum.gpurcell.com/
Title: Re: Bookmark Mod
Post by: RoarinRow on December 26, 2006, 05:57:31 PM
Very cool, thanks for updating for 1.1.1    ;)  I just had to manually add the array 'Bookmarks' to my custom theme's index.template.php file.

From the package:

if (in_array($context['current_action'], array('search', 'admin', 'calendar', 'profile', 'mlist', 'register', 'login', 'help', 'pm')))
      $current_action = $context['current_action'];]]></search>
        <add><![CDATA[
                if (in_array($context['current_action'], array('Bookmarks', 'search', 'admin', 'calendar', 'profile', 'mlist', 'register', 'login', 'help', 'pm')))
                  $current_action = $context['current_action'];

Title: Re: Bookmark Mod
Post by: 4fit? on December 27, 2006, 04:47:33 PM
SMF Version: 1.1.1
Quote from: bambi on December 26, 2006, 02:49:41 PM
   
Install mod.
You must ignore warnings, and continue with the installation.

Finally, you will introduce modifications in the following files.

default\Display.template.php
Search:

//SHOW THE LINKTREE:

Add below
//this is for the messages of the bookmarks:
        if(isset($context['bookmark_message']))
                echo $context['bookmark_message'];

index.php
Search:
'.xml' => array('News.php', 'ShowXmlFeed'),
Add below
'Bookmarks' => array('Bookmark.php', 'ShowBookmarks'),

You can test it in my site: 
User: test
Password: test
So, we install the mod that mgillespie posted and then apply these changes?  Am I correct in this?  I think my users would really like something like this and I am getting an error on Display.template.php when trying to install through the Package Manager.
Title: Re: Bookmark Mod
Post by: Gobo on December 27, 2006, 05:20:59 PM
ur changes will depend on IF and WHICH files the modifications fail on

as u can see for everyone it was different
Title: Re: Bookmark Mod
Post by: 4fit? on December 27, 2006, 07:15:38 PM
Quote from: akulion on December 27, 2006, 05:20:59 PM
ur changes will depend on IF and WHICH files the modifications fail on

as u can see for everyone it was different
OK, I have absolutely no idea what code to edit.  Like I said in the first post, I get an error on Display.template.php when trying to install using the Package Manager.  I know zilch about php coding, so, unfortunately, I need a little hand holding at the moment.
Title: Re: Bookmark Mod
Post by: Gobo on December 27, 2006, 07:35:03 PM
display.template.php file has 2 modifications
if u have other mods installed OR ur using a different theme there will be slight differences here and there

so if u cant find the whole code, try searcing for a single line from the code making sure there arent more codes like that around (just compare the full code to what follows the line to make sure its the correct part)

either ways make a BACKUP of the files before proceeding

First find:

$normal_buttons = array(
'reply' => array('test' => 'can_reply', 'text' => 146, 'image' => 'reply.gif', 'lang' => true, 'url' => $scripturl . '?action=post;topic=' . $context['current_topic'] . '.' . $context['start'] . ';num_replies=' . $context['num_replies']),
'notify' => array('test' => 'can_mark_notify', 'text' => 125, 'image' => 'notify.gif', 'lang' => true, 'custom' => 'onclick="return confirm(\'' . ($context['is_marked_notify'] ? $txt['notification_disable_topic'] : $txt['notification_enable_topic']) . '\');"', 'url' => $scripturl . '?action=notify;sa=' . ($context['is_marked_notify'] ? 'off' : 'on') . ';topic=' . $context['current_topic'] . '.' . $context['start'] . ';sesc=' . $context['session_id']),
'custom' => array(),
'send' => array('test' => 'can_send_topic', 'text' => 707, 'image' => 'sendtopic.gif', 'lang' => true, 'url' => $scripturl . '?action=sendtopic;topic=' . $context['current_topic'] . '.0'),
'print' => array('text' => 465, 'image' => 'print.gif', 'lang' => true, 'custom' => 'target="_blank"', 'url' => $scripturl . '?action=printpage;topic=' . $context['current_topic'] . '.0'),
);


replace it with:

$normal_buttons = array(
'reply' => array('test' => 'can_reply', 'text' => 146, 'image' => 'reply.gif', 'lang' => true, 'url' => $scripturl . '?action=post;topic=' . $context['current_topic'] . '.' . $context['start'] . ';num_replies=' . $context['num_replies']),
'bookmark' => array('test' => 'can_reply', 'image' => 'print.gif', 'text' => 'bookmark', 'lang' => true, 'url' => $scripturl . '?topic=' . $context['current_topic'] . '.0;do=Bookmark'),
    'notify' => array('test' => 'can_mark_notify', 'text' => 125, 'image' => 'notify.gif', 'lang' => true, 'custom' => 'onclick="return confirm(\'' . ($context['is_marked_notify'] ? $txt['notification_disable_topic'] : $txt['notification_enable_topic']) . '\');"', 'url' => $scripturl . '?action=notify;sa=' . ($context['is_marked_notify'] ? 'off' : 'on') . ';topic=' . $context['current_topic'] . '.' . $context['start'] . ';sesc=' . $context['session_id']),
'custom' => array(),
'send' => array('test' => 'can_send_topic', 'text' => 707, 'image' => 'sendtopic.gif', 'lang' => true, 'url' => $scripturl . '?action=sendtopic;topic=' . $context['current_topic'] . '.0'),
'print' => array('text' => 465, 'image' => 'print.gif', 'lang' => true, 'custom' => 'target="_blank"', 'url' => $scripturl . '?action=printpage;topic=' . $context['current_topic'] . '.0'),
);


then in the same file find:


// Show the linktree


add before it:

        //this is for the messages of the bookmarks:
        if(isset($context['bookmark_message']))
                echo $context['bookmark_message'];


thats it
Title: Re: Bookmark Mod
Post by: 4fit? on December 27, 2006, 07:56:25 PM
akulion, you da man!  Thanks for the hand holding!  It is greatly appreciated!!!
Title: Re: Bookmark Mod
Post by: RoarinRow on December 27, 2006, 08:37:03 PM
Quote from: 4fit? on December 27, 2006, 07:56:25 PM
akulion, you da man!  Thanks for the hand holding!  It is greatly appreciated!!!

I have the same fix, the only thing I did differently was to use Bloc's button generator to create a 'bookmark' button for some of my custom themes insteading of having two print.gif buttons from this code above:

'bookmark' => array('test' => 'can_reply', 'image' => 'print.gif', 'text' => 'bookmark', 'lang' => true, 'url' => $scripturl
Title: Re: Bookmark Mod
Post by: Gobo on December 27, 2006, 09:09:36 PM
yea same here had to make a custom button for Neon Theme lol
Title: Re: Bookmark Mod
Post by: RoarinRow on December 27, 2006, 09:40:04 PM
Quote from: akulion on December 27, 2006, 09:09:36 PM
yea same here had to make a custom button for Neon Theme lol

I looked and looked and said, wth! two print buttons, but the first one, when you hover over it, is the bookmark button   ;)
Title: Re: Bookmark Mod
Post by: Gobo on December 27, 2006, 10:03:18 PM
incase u dont have a bookmark button (and name it in the code with the name of a non existant file) then it automaticaly places a text link in its place
Title: Re: Bookmark Mod
Post by: B Patterson on January 02, 2007, 11:52:49 AM
Leipe:

Are you going to release an update for 1.1.1?  I would love to use it, but I'm not using 1.1RC2 anymore (don't even have the source) and have users that have requested this mod.  Since you seem to have done a fine-job of it already, I see no need to overwrite what you've done.
Title: Re: Bookmark Mod
Post by: Gobo on January 02, 2007, 05:53:44 PM
bpat read this post
http://www.simplemachines.org/community/index.php?topic=89003.msg876248#msg876248

it works for 1.1.1 (the package attached to that post)
Title: Re: Bookmark Mod
Post by: B Patterson on January 02, 2007, 06:26:58 PM
Thanks, totally missed that.
Title: Re: Bookmark Mod
Post by: Mr. Jinx on January 12, 2007, 07:57:13 AM
Very nice and easy mod. Great!
Just installed it on SMF 1.1.1
I had to manually create the bookmark table. There was some kind of old bookmark table I had to remove.

Anyway, if you would like a dutch translation of this mod, here it is.
You should put this somewhere in ../YourTheme/languages/Modifications.dutch.php.
The original location was index.english.php (which is wrong, should be Modifications.english.php)

$txt['bookmark'] = 'Favoriet';
$txt['bookmarks'] = 'Favorieten';
$txt['bookmark_open_new'] = 'Nieuw venster';
$txt['bookmark_delete'] = 'Verwijder';
$txt['bookmark_delete_msg'] = 'Favoriet verwijderd';
$txt['bookmark_delete_error1'] = 'Favoriet kon niet worden verwijderd';
$txt['bookmark_delete_error2'] = 'Het favoriet id komt niet overeen';
$txt['bookmark_delete_error3'] = 'Het favoriet id moet een nummer zijn';
$txt['bookmark_auto_delete_msg'] = 'Een aantal van uw favorieten zijn verwijderd omdat het desbetreffende topic niet meer bestaat';
$txt['bookmark_success'] = 'Het onderwerp is aan uw favorieten toegevoegd';
$txt['bookmark_exists'] = 'Het onderwerp was al aan uw favorieten toegevoegd';
$txt['bookmark_failed'] = 'Er ging iets fout met het toevoegen van het onderwerp aan uw favorieten';
$txt['my_bookmarks'] = 'Mijn Favorieten';
Title: Re: Bookmark Mod
Post by: Leipe Po on January 12, 2007, 08:04:44 PM
sorry i no langer have the time to update this code,
however anybody who wants to is free to modiiefy the code and release it under his/her name,
again i'm verry sorry,

Greetz Leipe_Po
Title: Re: Bookmark Mod
Post by: Greek on January 15, 2007, 10:35:39 AM
Pretty mod, but some more elements would be nice. I mean, next to topics, in bookmark's list, to appear new message icon (if exists), last poster name, date e.t.c, like VBulletin.
Title: Re: Bookmark Mod
Post by: [Duncan] on January 25, 2007, 07:35:36 PM
hello,

i realize a translation for this mod in French.
And a i change it for work properly with tinyportal 0.9.7.

   
you can do of them what you want :)

edit: just correction off language files.
Title: Re: Bookmark Mod
Post by: .Darkman on February 04, 2007, 10:56:43 AM
Will this work in 1.1.1 ?
Title: Re: Bookmark Mod
Post by: RavenLife on February 05, 2007, 03:21:02 PM
umm

seems i am having a problem of having two buttons both saying "my bookmark's"

each button work correctly - and when i click one they both light up to say there open

i found that index.english.php in the language files had two exact same colums of text (see below)

i deleted one of these but still i get the two buttons

anyone know where i can delete these to get rid

thanks

RL

Quote// a whole special block for the bookmark mod!!!:
$txt['bookmark'] = 'Bookmark';
$txt['bookmarks'] = 'Bookmarks';
$txt['bookmark_open_new'] = 'New window';
$txt['bookmark_delete'] = 'Delete';
$txt['bookmark_delete_msg'] = 'Bookmark deleted!!!';
$txt['bookmark_delete_error1'] = 'Sorry, cannot delete the bookmark youve selected!!!';
$txt['bookmark_delete_error2'] = 'Please fill in a bookmark id!!!';
$txt['bookmark_delete_error3'] = 'Please make sure the delete id is a number!!!';
$txt['bookmark_auto_delete_msg'] = 'Some bookmarks are auto-deleted because the topic no longer exists, Sorry';
$txt['bookmark_success'] = 'The topic has been added to your bookmark\'s';
$txt['bookmark_exists'] = 'The topic has allready been bookmarked by you!!!';
$txt['bookmark_failed'] = 'Sorry, but the bookmark has failed, pleas contact the webmaster if this problem continous!!!';
$txt['my_bookmarks'] = 'My Bookmark\'s';
Title: Re: Bookmark Mod
Post by: 4fit? on February 05, 2007, 04:23:10 PM
Quote from: RavenLife on February 05, 2007, 03:21:02 PM
umm

seems i am having a problem of having two buttons both saying "my bookmark's"

each button work correctly - and when i click one they both light up to say there open

i found that index.english.php in the language files had two exact same colums of text (see below)

i deleted one of these but still i get the two buttons

anyone know where i can delete these to get rid

thanks

RL

Quote// a whole special block for the bookmark mod!!!:
$txt['bookmark'] = 'Bookmark';
$txt['bookmarks'] = 'Bookmarks';
$txt['bookmark_open_new'] = 'New window';
$txt['bookmark_delete'] = 'Delete';
$txt['bookmark_delete_msg'] = 'Bookmark deleted!!!';
$txt['bookmark_delete_error1'] = 'Sorry, cannot delete the bookmark youve selected!!!';
$txt['bookmark_delete_error2'] = 'Please fill in a bookmark id!!!';
$txt['bookmark_delete_error3'] = 'Please make sure the delete id is a number!!!';
$txt['bookmark_auto_delete_msg'] = 'Some bookmarks are auto-deleted because the topic no longer exists, Sorry';
$txt['bookmark_success'] = 'The topic has been added to your bookmark\'s';
$txt['bookmark_exists'] = 'The topic has allready been bookmarked by you!!!';
$txt['bookmark_failed'] = 'Sorry, but the bookmark has failed, pleas contact the webmaster if this problem continous!!!';
$txt['my_bookmarks'] = 'My Bookmark\'s';
Probably have a duplicate entry in index.template.php.  Go have a look there.
Title: Re: Bookmark Mod
Post by: 4fit? on February 05, 2007, 04:24:15 PM
Quote from: .Darkman on February 04, 2007, 10:56:43 AM
Will this work in 1.1.1 ?
Works in my 1.1.1.
Title: Re: Bookmark Mod
Post by: RavenLife on February 05, 2007, 05:08:11 PM
Quote from: 4fit? on February 05, 2007, 04:23:10 PM
Quote from: RavenLife on February 05, 2007, 03:21:02 PM
umm

seems i am having a problem of having two buttons both saying "my bookmark's"

each button work correctly - and when i click one they both light up to say there open

i found that index.english.php in the language files had two exact same colums of text (see below)

i deleted one of these but still i get the two buttons

anyone know where i can delete these to get rid

thanks

RL

Quote// a whole special block for the bookmark mod!!!:
$txt['bookmark'] = 'Bookmark';
$txt['bookmarks'] = 'Bookmarks';
$txt['bookmark_open_new'] = 'New window';
$txt['bookmark_delete'] = 'Delete';
$txt['bookmark_delete_msg'] = 'Bookmark deleted!!!';
$txt['bookmark_delete_error1'] = 'Sorry, cannot delete the bookmark youve selected!!!';
$txt['bookmark_delete_error2'] = 'Please fill in a bookmark id!!!';
$txt['bookmark_delete_error3'] = 'Please make sure the delete id is a number!!!';
$txt['bookmark_auto_delete_msg'] = 'Some bookmarks are auto-deleted because the topic no longer exists, Sorry';
$txt['bookmark_success'] = 'The topic has been added to your bookmark\'s';
$txt['bookmark_exists'] = 'The topic has allready been bookmarked by you!!!';
$txt['bookmark_failed'] = 'Sorry, but the bookmark has failed, pleas contact the webmaster if this problem continous!!!';
$txt['my_bookmarks'] = 'My Bookmark\'s';
Probably have a duplicate entry in index.template.php.  Go have a look there.

so right, damn php editor wasnt skipping past the first reference

thanks
Title: Re: Bookmark Mod
Post by: RavenLife on February 06, 2007, 02:20:23 PM
Does anyone know how to modify this to work with other themes

im trying to get this working on a friends site using Blocs Amber Theme

as you can see on my test site http://testing.wiisrus.com/index.php

QuoteUSERNAME - test
PASSWORD - test1

as you can see when you login i have managed to get it on the main menu (minus) the image ??

but i cant seem to get them into the threads (so you can actually bookmark)

as you will notice when click bookmark - the page is slightly out

i have added and modified the code so it actually works!

(you can see this via switching to default theme, bookmarking a thread, and then switching back)

you will see that the bookmark page is working correctly (apart from images)

so my question is.

can anyone help

Thanks

RL
Title: Re: Bookmark Mod
Post by: 4fit? on February 06, 2007, 06:40:22 PM
Open up the modification xml file and perform the changes manually.
Title: Re: Bookmark Mod
Post by: RavenLife on February 06, 2007, 07:22:26 PM
Quotei have added and modified the code so it actually works!

i did that...

it just doesnt seem to work
Title: Re: Bookmark Mod
Post by: RavenLife on February 07, 2007, 04:59:32 PM
anyone willing to help
Title: Re: Bookmark Mod
Post by: RODEOSOLSTICE on February 08, 2007, 10:48:17 PM
didn
Quote from: 4fit? on February 05, 2007, 04:24:15 PM
Quote from: .Darkman on February 04, 2007, 10:56:43 AM
Will this work in 1.1.1 ?
Works in my 1.1.1.
Didn't werk on my 1.1.1 :(

I'm using the default theme...

here's the error on install:

1.     Execute Modification     ./Sources/Display.php     Test successful
2.    Execute Modification    ./Themes/default/Display.template.php    Test failed
3.    Execute Modification    ./Themes/default/index.template.php    Test failed
4.    Execute Modification    ./index.php    Test failed
5.    Execute Modification    ./Themes/default/languages/index.english.php    Test successful
6.    Extract File    ./Sources/Bookmark.php    
7.    Extract File    ./Themes/default/Bookmark.template.php    
8.    Execute Code    create_table.php    
Title: Re: Bookmark Mod
Post by: RavenLife on February 09, 2007, 12:23:59 AM
you need to add those codes yourself
Title: Re: Bookmark Mod
Post by: RODEOSOLSTICE on February 09, 2007, 11:12:25 AM
Quote from: RavenLife on February 09, 2007, 12:23:59 AM
you need to add those codes yourself

can anyone walk me thru it? I didn't see it here in this thread, maybe I missed it.

thanks!
Title: Re: Bookmark Mod
Post by: RavenLife on February 09, 2007, 11:51:22 AM
it is in this topic

see this page - http://www.simplemachines.org/community/index.php?topic=89003.60

Quote from: akulion on December 27, 2006, 07:35:03 PM
display.template.php file has 2 modifications
if u have other mods installed OR ur using a different theme there will be slight differences here and there

so if u cant find the whole code, try searcing for a single line from the code making sure there arent more codes like that around (just compare the full code to what follows the line to make sure its the correct part)

either ways make a BACKUP of the files before proceeding

First find:

$normal_buttons = array(
'reply' => array('test' => 'can_reply', 'text' => 146, 'image' => 'reply.gif', 'lang' => true, 'url' => $scripturl . '?action=post;topic=' . $context['current_topic'] . '.' . $context['start'] . ';num_replies=' . $context['num_replies']),
'notify' => array('test' => 'can_mark_notify', 'text' => 125, 'image' => 'notify.gif', 'lang' => true, 'custom' => 'onclick="return confirm(\'' . ($context['is_marked_notify'] ? $txt['notification_disable_topic'] : $txt['notification_enable_topic']) . '\');"', 'url' => $scripturl . '?action=notify;sa=' . ($context['is_marked_notify'] ? 'off' : 'on') . ';topic=' . $context['current_topic'] . '.' . $context['start'] . ';sesc=' . $context['session_id']),
'custom' => array(),
'send' => array('test' => 'can_send_topic', 'text' => 707, 'image' => 'sendtopic.gif', 'lang' => true, 'url' => $scripturl . '?action=sendtopic;topic=' . $context['current_topic'] . '.0'),
'print' => array('text' => 465, 'image' => 'print.gif', 'lang' => true, 'custom' => 'target="_blank"', 'url' => $scripturl . '?action=printpage;topic=' . $context['current_topic'] . '.0'),
);


replace it with:

$normal_buttons = array(
'reply' => array('test' => 'can_reply', 'text' => 146, 'image' => 'reply.gif', 'lang' => true, 'url' => $scripturl . '?action=post;topic=' . $context['current_topic'] . '.' . $context['start'] . ';num_replies=' . $context['num_replies']),
'bookmark' => array('test' => 'can_reply', 'image' => 'print.gif', 'text' => 'bookmark', 'lang' => true, 'url' => $scripturl . '?topic=' . $context['current_topic'] . '.0;do=Bookmark'),
    'notify' => array('test' => 'can_mark_notify', 'text' => 125, 'image' => 'notify.gif', 'lang' => true, 'custom' => 'onclick="return confirm(\'' . ($context['is_marked_notify'] ? $txt['notification_disable_topic'] : $txt['notification_enable_topic']) . '\');"', 'url' => $scripturl . '?action=notify;sa=' . ($context['is_marked_notify'] ? 'off' : 'on') . ';topic=' . $context['current_topic'] . '.' . $context['start'] . ';sesc=' . $context['session_id']),
'custom' => array(),
'send' => array('test' => 'can_send_topic', 'text' => 707, 'image' => 'sendtopic.gif', 'lang' => true, 'url' => $scripturl . '?action=sendtopic;topic=' . $context['current_topic'] . '.0'),
'print' => array('text' => 465, 'image' => 'print.gif', 'lang' => true, 'custom' => 'target="_blank"', 'url' => $scripturl . '?action=printpage;topic=' . $context['current_topic'] . '.0'),
);


then in the same file find:


// Show the linktree


add before it:

        //this is for the messages of the bookmarks:
        if(isset($context['bookmark_message']))
                echo $context['bookmark_message'];


thats it
Title: Re: Bookmark Mod
Post by: RODEOSOLSTICE on February 09, 2007, 06:45:43 PM
thanks a bunch!!! Sorry to be such a newbie at this, I appreciate the help!!!
Title: Re: Bookmark Mod
Post by: RavenLife on February 09, 2007, 06:47:37 PM
no problem - if you need anymore help

just post or pm me your email/msn

good luck
Title: Re: Bookmark Mod
Post by: perplexed on February 10, 2007, 09:42:40 AM
Quote from: mgillespie on December 26, 2006, 12:59:12 PM
Any news on this? This is a really neat mod, and not having it for 1.1.1 is a problem for me, means I cannot update my forum software until this happens.

Seems the original author is not around that often, looking at the licence, it appears, as long as I upload any modded version here, and it benefits SMF, then we are free to do so.

I have modified Bookmark 1.2 to work with SMF 1.1.1 (ONLY this version).  I have re-labelled it 1.3.  Hopefully the original author is OK with this.

As usual this comes with no warranties, but it worked a treat on my SMF 1.1.1 installation, and the changes required should not have broken anything (whitespace tabulation has changed in the search criterea).

I have attached the mod, I hope it helps out others..  SMF seriously needs a thread bookmarker, and this is a very good implementation...

Quote from: bambi on December 26, 2006, 02:49:41 PM
   
Install mod.
You must ignore warnings, and continue with the installation.

Finally, you will introduce modifications in the following files.

default\Display.template.php
Search:

//SHOW THE LINKTREE:

Add below
//this is for the messages of the bookmarks:
        if(isset($context['bookmark_message']))
                echo $context['bookmark_message'];

index.php
Search:
'.xml' => array('News.php', 'ShowXmlFeed'),
Add below
'Bookmarks' => array('Bookmark.php', 'ShowBookmarks'),

You can test it in my site: 
User: test
Password: test

I really don't want to install this with errors in the install.  the second quoted message - where it says 'ignore warnings.. continue install...'  is that related to the version in the post above which has been changed to work with 1.1.1 or is that related to another version, not a 1.1.1 version?

~thanks
Title: Re: Bookmark Mod
Post by: RavenLife on February 10, 2007, 09:56:06 AM
its related to the 1.1.1 - the reason you are ignoring warnings, is becuase you will be added the code yourself
Title: Re: Bookmark Mod
Post by: perplexed on February 10, 2007, 10:03:06 AM
so not related to the post above it, which was a package right?
Title: Re: Bookmark Mod
Post by: RavenLife on February 10, 2007, 10:04:39 AM
no you misunderstand

the package above it - is the modified bookmark mod to work with 1.1.1

THIS IS FOR USERS WITH THE AMBER THEME THAT WANT THE MOD

well i did it myself

so here are the files

install the mod

Place and replace all the files in the amber theme directory with the ones below

(warning - only do this if you have no other mods installed for this theme

then you will need to add this line to you index.php yourself

FIND
'.xml' => array('News.php', 'ShowXmlFeed'),

BEFORE ADD
'Bookmarks' => array('Bookmark.php', 'ShowBookmarks'),


the image goes in the images/english directory

the mods not perfect - but it works

thanks

RL

Title: Re: Bookmark Mod
Post by: perplexed on February 10, 2007, 12:56:25 PM
ok, sorry.  thanks
Title: Re: Bookmark Mod
Post by: dflora23 on February 13, 2007, 08:59:24 AM
Anyone get this to work with 1.12 yet?
Title: Re: Bookmark Mod
Post by: XP29F61 on February 18, 2007, 05:44:26 PM
I just got it working with 1.1.2.

Here is what I did.

I ran the install through the Package manager even with the errors....

Then I used these instructions.....

Quote from: akulion on December 27, 2006, 07:35:03 PM
display.template.php file has 2 modifications
if u have other mods installed OR ur using a different theme there will be slight differences here and there

so if u cant find the whole code, try searcing for a single line from the code making sure there arent more codes like that around (just compare the full code to what follows the line to make sure its the correct part)

either ways make a BACKUP of the files before proceeding

First find:

$normal_buttons = array(
'reply' => array('test' => 'can_reply', 'text' => 146, 'image' => 'reply.gif', 'lang' => true, 'url' => $scripturl . '?action=post;topic=' . $context['current_topic'] . '.' . $context['start'] . ';num_replies=' . $context['num_replies']),
'notify' => array('test' => 'can_mark_notify', 'text' => 125, 'image' => 'notify.gif', 'lang' => true, 'custom' => 'onclick="return confirm(\'' . ($context['is_marked_notify'] ? $txt['notification_disable_topic'] : $txt['notification_enable_topic']) . '\');"', 'url' => $scripturl . '?action=notify;sa=' . ($context['is_marked_notify'] ? 'off' : 'on') . ';topic=' . $context['current_topic'] . '.' . $context['start'] . ';sesc=' . $context['session_id']),
'custom' => array(),
'send' => array('test' => 'can_send_topic', 'text' => 707, 'image' => 'sendtopic.gif', 'lang' => true, 'url' => $scripturl . '?action=sendtopic;topic=' . $context['current_topic'] . '.0'),
'print' => array('text' => 465, 'image' => 'print.gif', 'lang' => true, 'custom' => 'target="_blank"', 'url' => $scripturl . '?action=printpage;topic=' . $context['current_topic'] . '.0'),
);


replace it with:

$normal_buttons = array(
'reply' => array('test' => 'can_reply', 'text' => 146, 'image' => 'reply.gif', 'lang' => true, 'url' => $scripturl . '?action=post;topic=' . $context['current_topic'] . '.' . $context['start'] . ';num_replies=' . $context['num_replies']),
'bookmark' => array('test' => 'can_reply', 'image' => 'print.gif', 'text' => 'bookmark', 'lang' => true, 'url' => $scripturl . '?topic=' . $context['current_topic'] . '.0;do=Bookmark'),
    'notify' => array('test' => 'can_mark_notify', 'text' => 125, 'image' => 'notify.gif', 'lang' => true, 'custom' => 'onclick="return confirm(\'' . ($context['is_marked_notify'] ? $txt['notification_disable_topic'] : $txt['notification_enable_topic']) . '\');"', 'url' => $scripturl . '?action=notify;sa=' . ($context['is_marked_notify'] ? 'off' : 'on') . ';topic=' . $context['current_topic'] . '.' . $context['start'] . ';sesc=' . $context['session_id']),
'custom' => array(),
'send' => array('test' => 'can_send_topic', 'text' => 707, 'image' => 'sendtopic.gif', 'lang' => true, 'url' => $scripturl . '?action=sendtopic;topic=' . $context['current_topic'] . '.0'),
'print' => array('text' => 465, 'image' => 'print.gif', 'lang' => true, 'custom' => 'target="_blank"', 'url' => $scripturl . '?action=printpage;topic=' . $context['current_topic'] . '.0'),
);


then in the same file find:


// Show the linktree


add before it:

        //this is for the messages of the bookmarks:
        if(isset($context['bookmark_message']))
                echo $context['bookmark_message'];


Then I used the instructions for the Index.php file below

Quote from: bambi on December 26, 2006, 02:49:41 PM
   
index.php
Search:
'.xml' => array('News.php', 'ShowXmlFeed'),
Add below
'Bookmarks' => array('Bookmark.php', 'ShowBookmarks'),

Except, you add it before the .xml code, not after.

Works like a charm.  
Title: Re: Bookmark Mod
Post by: GJ-tje on February 25, 2007, 11:37:01 AM
Quote from: XP29F61 on February 18, 2007, 05:44:26 PM
I just got it working with 1.1.2.

Here is what I did.

I ran the install through the Package manager even with the errors....

Then I used these instructions.....

Quote from: akulion on December 27, 2006, 07:35:03 PM
display.template.php file has 2 modifications
if u have other mods installed OR ur using a different theme there will be slight differences here and there

so if u cant find the whole code, try searcing for a single line from the code making sure there arent more codes like that around (just compare the full code to what follows the line to make sure its the correct part)

either ways make a BACKUP of the files before proceeding

First find:

$normal_buttons = array(
'reply' => array('test' => 'can_reply', 'text' => 146, 'image' => 'reply.gif', 'lang' => true, 'url' => $scripturl . '?action=post;topic=' . $context['current_topic'] . '.' . $context['start'] . ';num_replies=' . $context['num_replies']),
'notify' => array('test' => 'can_mark_notify', 'text' => 125, 'image' => 'notify.gif', 'lang' => true, 'custom' => 'onclick="return confirm(\'' . ($context['is_marked_notify'] ? $txt['notification_disable_topic'] : $txt['notification_enable_topic']) . '\');"', 'url' => $scripturl . '?action=notify;sa=' . ($context['is_marked_notify'] ? 'off' : 'on') . ';topic=' . $context['current_topic'] . '.' . $context['start'] . ';sesc=' . $context['session_id']),
'custom' => array(),
'send' => array('test' => 'can_send_topic', 'text' => 707, 'image' => 'sendtopic.gif', 'lang' => true, 'url' => $scripturl . '?action=sendtopic;topic=' . $context['current_topic'] . '.0'),
'print' => array('text' => 465, 'image' => 'print.gif', 'lang' => true, 'custom' => 'target="_blank"', 'url' => $scripturl . '?action=printpage;topic=' . $context['current_topic'] . '.0'),
);


replace it with:

$normal_buttons = array(
'reply' => array('test' => 'can_reply', 'text' => 146, 'image' => 'reply.gif', 'lang' => true, 'url' => $scripturl . '?action=post;topic=' . $context['current_topic'] . '.' . $context['start'] . ';num_replies=' . $context['num_replies']),
'bookmark' => array('test' => 'can_reply', 'image' => 'print.gif', 'text' => 'bookmark', 'lang' => true, 'url' => $scripturl . '?topic=' . $context['current_topic'] . '.0;do=Bookmark'),
    'notify' => array('test' => 'can_mark_notify', 'text' => 125, 'image' => 'notify.gif', 'lang' => true, 'custom' => 'onclick="return confirm(\'' . ($context['is_marked_notify'] ? $txt['notification_disable_topic'] : $txt['notification_enable_topic']) . '\');"', 'url' => $scripturl . '?action=notify;sa=' . ($context['is_marked_notify'] ? 'off' : 'on') . ';topic=' . $context['current_topic'] . '.' . $context['start'] . ';sesc=' . $context['session_id']),
'custom' => array(),
'send' => array('test' => 'can_send_topic', 'text' => 707, 'image' => 'sendtopic.gif', 'lang' => true, 'url' => $scripturl . '?action=sendtopic;topic=' . $context['current_topic'] . '.0'),
'print' => array('text' => 465, 'image' => 'print.gif', 'lang' => true, 'custom' => 'target="_blank"', 'url' => $scripturl . '?action=printpage;topic=' . $context['current_topic'] . '.0'),
);


then in the same file find:


// Show the linktree


add before it:

        //this is for the messages of the bookmarks:
        if(isset($context['bookmark_message']))
                echo $context['bookmark_message'];


Then I used the instructions for the Index.php file below

Quote from: bambi on December 26, 2006, 02:49:41 PM
   
index.php
Search:
'.xml' => array('News.php', 'ShowXmlFeed'),
Add below
'Bookmarks' => array('Bookmark.php', 'ShowBookmarks'),

Except, you add it before the .xml code, not after.

Works like a charm. 
Can you (or the creator) create a package so that it's easy to install on 1.1.2? :D

Thanks in advance!
Title: Re: Bookmark Mod
Post by: HecKel on March 01, 2007, 09:25:03 AM
Quote from: GJ-tje on February 25, 2007, 11:37:01 AM
Can you (or the creator) create a package so that it's easy to install on 1.1.2? :D

Thanks in advance!
A little bump :P

I am interested in this mod too ;)

HecKel
Title: Re: Bookmark Mod
Post by: bambi on March 03, 2007, 04:44:26 PM
Quote from: GJ-tje on February 25, 2007, 11:37:01 AM
Can you (or the creator) create a package so that it's easy to install on 1.1.2? :D
Thanks in advance!

The creator is Leipe Po: http://www.simplemachines.org/community/index.php?topic=89003.msg905651#msg905651
Title: Re: Bookmark Mod
Post by: ckgb on March 15, 2007, 05:59:16 PM
Thanks for the tips. It was very easy to make it work
Title: Re: Bookmark Mod
Post by: TrueSatan on March 15, 2007, 07:27:14 PM
 I've used this modified package myself but haven't given it extensive testing...seems to be OK though. Use it but don't moan if I've missed something.

On forums with mods installed index.php will probably show a fail in the package manager install...a manual install into that file will be needed after running the package manager...it's easy.

The last time I bothered to publish an updated package I got abuse from another member...I'd be pleased if that didn't happen again...call it a hint.

Anyhow I hope it helps those who requested same...

Title: Re: Bookmark Mod
Post by: edwardsiow on March 15, 2007, 10:33:53 PM
for default theme, GJ-tje's tricks work! i have tried...
Title: Re: Bookmark Mod
Post by: edwardsiow on March 20, 2007, 01:19:28 PM
sombody know how to make the bookmark works under Seo4SMF??
Title: Re: Bookmark Mod
Post by: rosey on April 02, 2007, 05:41:37 PM
Quote from: TrueSatan on March 15, 2007, 07:27:14 PM
I've used this modified package myself but haven't given it extensive testing...seems to be OK though. Use it but don't moan if I've missed something.

worked great for me, thanks!
Title: Re: Bookmark Mod
Post by: TrueSatan on April 02, 2007, 05:59:06 PM
 I've been using it on a number of active forums for a while now without problems.

Anyhow...thanks rosey for taking the effort to give some feedback.
Title: Re: Bookmark Mod
Post by: ltdeta on April 22, 2007, 09:12:28 AM
when will 1.3 arrive  ;)
Title: Re: Bookmark Mod
Post by: shadow82x on April 25, 2007, 10:15:53 PM
Is there a code if you wanted to add it in just your profile? Not on the nav. bar?
Title: Re: Bookmark Mod
Post by: TrueSatan on April 26, 2007, 04:00:21 AM
Not as such nor is one needed...you could leave out the addition of the button in a manual install (or remove it after an automated one) and then add the link to your profile...it's as follows:

http://yoursite.com/index.php?action=Bookmarks

...actually you could go to ACP>Features and Options>Basic Features>Default personal text

...and add it there.
Title: Re: Bookmark Mod
Post by: karlbenson on May 24, 2007, 06:25:58 PM
Hope the original author or TrueSatan don't mind.I've fixed two errors/problems with TrueSatans version.
I really wanted to use it for my forum.

1) when deleting a bookmark, the alert would be added before the <doc type> and so would cause the text to go super large in IE. I've made any alerts pass via a $bookmark_msgs variable to the template so that it is written in the text.

2) when viewing the bookmark area with no bookmarks, there was an error because the mod does a foreach loop with an empty string.

See attachment.
Title: Re: Bookmark Mod
Post by: TrueSatan on May 24, 2007, 07:10:18 PM
I certainly don't mind...far from it. Thank you for improving this mod!

The original author emigrated from the UK to Hong Kong and doesn't seem to have come to this site again following that move and given that a fair bit of time has now passed by it's getting less and less likely that we'll see him again.

It might be also difficult to contact him to formally take over the mod supposing he'd be willing to have this done...this puts us in a bit of a spot with regard to SMF rules as without his permission the mod can't be taken over so we can only post updates via this forum...maybe if we get far enough away, in terms of the code, from the last official version this might change but SMF rules seem to me so say that a proposed mod that is sufficiently like an existing mod will be rejected.
Title: Re: Bookmark Mod
Post by: shadow82x on May 24, 2007, 07:21:56 PM
So is there a way to get a link in your profile saying bookmarks? (Not including the one on the nav. bar)
Title: Re: Bookmark Mod
Post by: TrueSatan on May 24, 2007, 08:43:00 PM
@shadow82x Given that when I tried to give you some assistance re this request last time you made it you didn't bother to reply my willingness to help you is a diminishing resource!

You could add to Modifications.english.php:


//Begin Bookmark Mod
$txt['profile_show_bookmarks'] = 'Show my bookmarks';
//End Bookmark Mod



and to profile.template.php immediately following

<a href="', $scripturl, '?action=profile;u=', $context['member']['id'], ';sa=showPosts">', $txt[460], ' ', $txt[461], '.</a><br />
<a href="', $scripturl, '?action=profile;u=', $context['member']['id'], ';sa=statPanel">', $txt['statPanel_show'], '.</a><br />


the following:

<br /><a href="', $scripturl, '?action=Bookmarks">', $txt['profile_show_bookmarks'], '.</a><br />

This would add a line at the end of the profile page that read "Show my bookmarks." and would take the person viewing it to their bookmarks. It wouldn't take them to the bookmarks of another member if they were viewing that member's profile as I don't think it wise to allow members to view one another's bookmarks.
Title: Re: Bookmark Mod
Post by: shadow82x on May 24, 2007, 08:54:49 PM
Thank you very much! :)
Title: Re: Bookmark Mod
Post by: TrueSatan on May 24, 2007, 08:56:37 PM
My pleasure...I hope it's what you wanted.
Title: Re: Bookmark Mod
Post by: shadow82x on May 24, 2007, 09:02:13 PM
It is I will try the mod. tomorrow and ill tell you how it goes :)
Title: Re: Bookmark Mod
Post by: TrueSatan on May 24, 2007, 09:41:37 PM
OK...my availability on line might be limited tomorrow if you need any problems fixed but I don't think you'll have any anyhow.
Title: Re: Bookmark Mod
Post by: Lew Cipher on May 24, 2007, 10:23:51 PM
This is an excellent mod but very difficult to get working properly in the newest version. I got it working thanks to the advice from several people in this thread.

Thanks to you all.  :)
Title: Re: Bookmark Mod
Post by: TrueSatan on May 25, 2007, 04:04:54 AM
Quote from: Lew Cipher on May 24, 2007, 10:23:51 PM
This is an excellent mod but very difficult to get working properly in the newest version. I got it working thanks to the advice from several people in this thread.

Thanks to you all.  :)

I really don't see that at all...if you use the latest version...kindly posted by Karlbenson...then what is the difficulty? You don't need to do any extra code edits if the package installer works for you...and if it doesn't that's not the fault of this mod but due to your having other mods that have already altered the files it seeks to alter...same with any mod.

What precisely makes you say it is
Quotevery difficult to get working properly in the newest version
as I'd say the opposite was the case.
Title: Re: Bookmark Mod
Post by: shadow82x on May 25, 2007, 11:57:50 AM
Quote from: TrueSatan on May 24, 2007, 08:43:00 PM
@shadow82x Given that when I tried to give you some assistance re this request last time you made it you didn't bother to reply my willingness to help you is a diminishing resource!

You could add to Modifications.english.php:


//Begin Bookmark Mod
$txt['profile_show_bookmarks'] = 'Show my bookmarks';
//End Bookmark Mod



and to profile.template.php immediately following

<a href="', $scripturl, '?action=profile;u=', $context['member']['id'], ';sa=showPosts">', $txt[460], ' ', $txt[461], '.</a><br />
<a href="', $scripturl, '?action=profile;u=', $context['member']['id'], ';sa=statPanel">', $txt['statPanel_show'], '.</a><br />


the following:

<br /><a href="', $scripturl, '?action=Bookmarks">', $txt['profile_show_bookmarks'], '.</a><br />

This would add a line at the end of the profile page that read "Show my bookmarks." and would take the person viewing it to their bookmarks. It wouldn't take them to the bookmarks of another member if they were viewing that member's profile as I don't think it wise to allow members to view one another's bookmarks.
Can you tell me exactly where to insert them? Like under whatever
Title: Re: Bookmark Mod
Post by: TrueSatan on May 25, 2007, 12:58:24 PM
The Modifications.english.php change could go almost anywhere in that file...you can put it at the end of the other mod code additions if you like. The file must always end with ?> so move that code such that it is at the end of the file on it's own line and put the edit before it.

I couldn't say add before whatever as I don't know what else you have in that file from other mods.

I've already said exactly where to add the edit for profile.template.php so you should know how to handle that from my previous reply.

It's a very easy edit so I you will now be OK with it...if not you'd best post your files here as attachments and let me then do the edits and repost the edited files for you.
Title: Re: Bookmark Mod
Post by: shadow82x on May 25, 2007, 01:51:52 PM
I did it but it does not show anything in the profile
Title: Re: Bookmark Mod
Post by: TrueSatan on May 25, 2007, 02:09:38 PM
I presume that you also edited your Modifications.english.php file?

Might I have a link to your site and a test account...perhaps you'd PM me the details?
Title: Re: Bookmark Mod
Post by: shadow82x on May 25, 2007, 02:25:09 PM
ok should it have admin permissions?
Title: Re: Bookmark Mod
Post by: TrueSatan on May 25, 2007, 02:30:28 PM
No...no need for them as this edit just lets members see their own bookmarks in the same way as the nav bar button does...you only asked for the nav bar button to be dispensed with and a link in the profile to stand in its place.
Title: Re: Bookmark Mod
Post by: shadow82x on May 25, 2007, 02:33:05 PM
Yes thats what I want
Title: Re: Bookmark Mod
Post by: TrueSatan on May 25, 2007, 02:48:49 PM
Hmmm...might I see your Modifications.english.php...please post it here as an attachment...thanks.

BTW this is what you should have...plus your topics link

Title: Re: Bookmark Mod
Post by: shadow82x on May 25, 2007, 02:53:15 PM
Modification English Attachment:
Title: Re: Bookmark Mod
Post by: shadow82x on May 25, 2007, 02:54:13 PM
Quote from: TrueSatan on May 25, 2007, 02:48:49 PM
Hmmm...might I see your Modifications.english.php...please post it here as an attachment...thanks.

BTW this is what you should have...plus your topics link


Yes I dont have that
Title: Re: Bookmark Mod
Post by: TrueSatan on May 25, 2007, 03:28:09 PM
Your Modifications.english.php file raises a number of concerns with me...it contains a duplicated mod and a triplicated mod indicating that one is installed into it twice over and the other three times over and thus might also be in other files twice/three times over...I'll tidy it up and remove the duplications and triplications but you need to check the following mods and the files they install into to see if they are duplicated or triplicated in other files.

SMFBlog (double installed)

User Email System (triple installed)

I've tidied up the installation of the edit in your profile.template.php file too...uploaded below...can you please rename your old files so you don't lose them then upload the files below to your site and when done let me know so I can have a look at that test account again...BTW removing the button for the bookmarks from your nav bar is easy but let's get this done first.
Title: Re: Bookmark Mod
Post by: shadow82x on May 25, 2007, 03:39:30 PM
So replace that with the current?
Title: Re: Bookmark Mod
Post by: shadow82x on May 25, 2007, 03:45:27 PM
OK I got it to work there but one more thing.. Is there a way to make it show on the sidebar too?
Title: Re: Bookmark Mod
Post by: TrueSatan on May 25, 2007, 03:49:49 PM
When I have more time I'll have a think about that one (I'm my very elderly and infirm mother's carer so real life issues have to come first.)

Precisely where do you want the link now?
Title: Re: Bookmark Mod
Post by: shadow82x on May 25, 2007, 04:01:25 PM
ON the sidebar where it says "Modify"

(http://img161.imageshack.us/img161/3756/untitledef6.png)

Title: Re: Bookmark Mod
Post by: TrueSatan on May 25, 2007, 07:57:27 PM
I'll try to spend time on it this weekend and see what I can do for you.
Title: Re: Bookmark Mod
Post by: shadow82x on May 25, 2007, 08:26:47 PM
Quote from: TrueSatan on May 25, 2007, 07:57:27 PM
I'll try to spend time on it this weekend and see what I can do for you.
Thanks :)
Title: Re: Bookmark Mod
Post by: PipeRain on May 29, 2007, 07:03:21 PM
Okay, I hope I haven't missed something in this thread, but I am trying to install this using karlbenson's mod of TrueSatans mod of the original.  However, when I attempt to install via package manager, I get errors on "./Themes/default/Display.template.php" and "./Themes/default/index.template.php" as seen below:

(http://img258.imageshack.us/img258/9397/bookmarkerrorqx0.png)

I will attach the "offending files" in case that helps....

Thank you in advance for any help you can provide.
Title: Re: Bookmark Mod
Post by: shadow82x on May 29, 2007, 07:26:04 PM
Probably other mods interfering with this. What other mods do you have installed?
Title: Re: Bookmark Mod
Post by: TrueSatan on May 29, 2007, 07:26:18 PM
Quote from: shadow82x on May 25, 2007, 08:26:47 PM
Quote from: TrueSatan on May 25, 2007, 07:57:27 PM
I'll try to spend time on it this weekend and see what I can do for you.
Thanks :)

Haven't forgotten...it was a rather tough weekend so I didn't have time for coding but I'll try do sort something out before too long.
Title: Re: Bookmark Mod
Post by: TrueSatan on May 29, 2007, 07:35:37 PM
Quote from: shadow82x on May 29, 2007, 07:26:04 PM
Probably other mods interfering with this. What other mods do you have installed?

Yes...exactly right.

When a mod tries to install via the package manager system it will fail if other mods have been installed and affected the areas in files it needs to edit...it then gives the errors you've seen.

You should do a manual install...see these links:

http://docs.simplemachines.org/index.php?topic=402 (http://docs.simplemachines.org/index.php?topic=402)

http://modparser.dev.dansoftaustralia.net/ (http://modparser.dev.dansoftaustralia.net/)

The fails don't mean that there is anything wrong with this mod or any of the other mods you&nbsp; may have installed.

What you can also do...and you need to do this exactly as I detail...is to install the mod ignoring the fail...download the files that were listed as fails to your computer (they may have had a partial install so they might not be exactly the same as those you have provided here)...manually install the mod into them referring to the above links for help in so doing...rename the files on your server so you keep the existing versions in case anything goes wrong...upload your edited files to your server.

Looking at the two files you provided there will be a mod conflict...I can't, off hand, identify the mod that is there already but the editing around it might give you some difficulty so I've done the work for you...there is a little juggling involved so if you get a problem you may need to ask for more assistance but I think they'll be OK.
Title: Re: Bookmark Mod
Post by: PipeRain on May 29, 2007, 08:46:18 PM
Thanks to Shadow 82X and TrueSatan for the quick replies, and all the work.

I'll give it a go, and report back either way.

Again, thank you for your help.
Title: Re: Bookmark Mod
Post by: TrueSatan on May 29, 2007, 08:51:50 PM
My pleasure...and firstly good luck with it...secondly I hope you enjoy the mod.
Title: Re: Bookmark Mod
Post by: PipeRain on May 29, 2007, 09:04:05 PM
<happy_dance>

It appears to have installed correctly.

</happy_dance>

Sorry, don't know how to code that properly in php.   :P
Title: Re: Bookmark Mod
Post by: TrueSatan on May 29, 2007, 09:53:05 PM
Mock html will do nicely.
Title: Re: Bookmark Mod
Post by: pvisser on May 31, 2007, 07:34:06 AM
Hi there. Cool and it works like a charm. I have one question do. Why i'm getting the message popup twice "Bookmark added to you bookmarks." after adding bookmark a topic. Normal i should be ones?. Please advice. Thanks..

SMF 1.1.2
Title: Re: Bookmark Mod
Post by: TrueSatan on May 31, 2007, 07:56:55 AM
It sounds as though you have parts of the mod installed twice over...Display.php entries might well have this effect. You need to check your files to see if this has happened...try using http://server.daniel15.com/smf/package.php (http://server.daniel15.com/smf/package.php) to get details of what edits the mod makes and then see if they have been doubled up in any of your files.
Title: Re: Bookmark Mod
Post by: pvisser on May 31, 2007, 08:08:04 AM
Thanks TrueSatan, Solved the Problem. I don't how how but the problem whas in the display.template.php. Coding twice. Now its working Perfect.. :) I'm Happy.
Title: Re: Bookmark Mod
Post by: TrueSatan on May 31, 2007, 08:18:16 AM
Great...good to hear...and thanks for replying so that we know your problem has been resolved.
Title: Re: Bookmark Mod
Post by: asd1 on June 08, 2007, 04:48:11 PM
when I want to install it it shows error. look (http://img527.imageshack.us/img527/8336/untitledih7.th.jpg) (http://img527.imageshack.us/my.php?image=untitledih7.jpg)
Title: Re: Bookmark Mod
Post by: TrueSatan on June 08, 2007, 05:33:58 PM
@ asd1

Your errors in the are due to the files in question having been changed by other mods you have installed.

Please read:

http://docs.simplemachines.org/index.php?topic=402.msg531#msg531 (http://docs.simplemachines.org/index.php?topic=402.msg531#msg531)

...and refer to:

http://server.daniel15.com/smf/package.php (http://server.daniel15.com/smf/package.php)
Title: Re: Bookmark Mod
Post by: asd1 on June 09, 2007, 08:37:22 AM
how to bookmark topic?
Title: Re: Bookmark Mod
Post by: TrueSatan on June 09, 2007, 09:06:24 AM
@ asd1

Use the topic navigation bar at the top of the topic area...it should contain a "Bookmark" option...see screenshot below.
Title: Re: Bookmark Mod
Post by: shadow82x on June 09, 2007, 03:12:59 PM
Satan ever figure out how to add it to the profile links
Title: Re: Bookmark Mod
Post by: TrueSatan on June 09, 2007, 03:27:18 PM
 I tried something but found that it would conflict with other mods if I gave you that fix (and it gave a few errors but those could be sorted out) so I'm still working on it...haven't given up yet.
Title: Re: Bookmark Mod
Post by: shadow82x on June 09, 2007, 03:38:58 PM
ok than
Title: Re: Bookmark Mod
Post by: dork313 on June 19, 2007, 03:21:38 AM
I've installed the mod manually on my custom theme and everything is working correctly except that when I click on the button to bookmarks the topic the pop up window tells me I've already bookmarked even though I hadn't.

Any suggestions?
Title: Re: Bookmark Mod
Post by: TrueSatan on June 19, 2007, 03:48:49 AM
Firstly does the mod work properly in the SMF default theme set to english and not english utf8? If it works in that configuration then save for suggesting that you refer to:

http://docs.simplemachines.org/index.php?topic=402.msg531#msg531 (http://docs.simplemachines.org/index.php?topic=402.msg531#msg531)

...I can't be of much help...though I would point out that not all mods will work in all themes.
Title: Re: Bookmark Mod
Post by: dork313 on June 19, 2007, 04:22:36 AM
Thanks but I fixed it.
Title: Re: Bookmark Mod
Post by: ltdeta on June 21, 2007, 10:52:12 AM
using bookmarks alway the position is on last posting on the page

is it possible make it alternative on the first posting
Title: Re: Bookmark Mod
Post by: TrueSatan on June 21, 2007, 12:16:35 PM
Quote from: ltdeta on June 21, 2007, 10:52:12 AM
using bookmarks alway the position is on last posting on the page

is it possible make it alternative on the first posting


Your question does not fit what the mod does...the mod bookmarks topics not postings so having the option to bookmark a topic at the end of the topic is sensible and puts the option with the other options relating to each topic.
Title: Re: Bookmark Mod
Post by: RiderRaghav on June 29, 2007, 11:43:10 PM
Will it work on smf v1.1.3 ... ???
 
Thanks in advance ;)
Title: Re: Bookmark Mod
Post by: TrueSatan on June 30, 2007, 05:10:41 AM
@ riderraghav

Rather than posting these (annoying) messages of yours on umpteen mod support topics why don't you just try each mod for yourself?

Had you tried Karlbenson's bug fix version posted on this topic you'd have found that it already works properly in SMF 1.1.3
Title: Re: Bookmark Mod
Post by: jafern on July 13, 2007, 05:37:22 PM
Hi @ all&nbsp; :)

tried this mod and had a few problems at the beginning, but now it works. At least it seems to...

Two things are making me crazy:

1. when I bookmark a topic first time I got the message "The topic has allready been bookmarked by you!!!" - what definitively not has been done&nbsp; >:(

2. when deleting a bookmark I got a white screen with the message "You can't access this file directly..."

In both cases at least the topic is bookmarked or deleted after, but still have these misleading messages.

Does anyone know why?

Thanks in advance..
jafern
Title: Re: Bookmark Mod
Post by: TrueSatan on July 13, 2007, 07:16:11 PM
I suspect that you have duplicated some of the code in your files...please check for this and remove as appropriate then try the mod again.
Title: Re: Bookmark Mod
Post by: jafern on July 14, 2007, 01:15:55 AM
Good morning and thanks for quick reply!

Indeed there was duplicate code in $sourcedir/Display.php, so I removed it and could solve the first problem. Great!

But the second one (when deleting a bookmark) is still existing...  ::)

Any idea about this?

Thanks and regards
jafern
Title: Re: Bookmark Mod
Post by: TrueSatan on July 14, 2007, 05:00:07 AM
...and good morning to you too.

I've never encountered the error you report, and can't duplicate it, but my best suggestion would be that, if there are no more file duplications (double check please), it is due to either CHMOD on the files or server configuration issues (the second is going to be a problem as I can't pinpoint what it might be about the configuration that might not like this mod)...the easy way to sort out your CHMOD is to go to:

ACP>Packages>Options

Set the "Installation Options boxes as appropriate to your server...in "Cleanup Permissions" set "All files are writeable" and then, via ftp, check that all your files have been changed to either CHMOD 775 or 777. You should do this prior to installing any mod or theme then, if you wish, use the same system to revert to a setting where less files are writeable.
Title: Re: Bookmark Mod
Post by: jafern on July 14, 2007, 05:21:25 AM
Hi&nbsp; ;)

did what you suggested, but situation is the same: after deleting a bookmark I still got the white sreen and "You can't access this file directly..."&nbsp; :(

kr
jafern
Title: Re: Bookmark Mod
Post by: TrueSatan on July 14, 2007, 06:30:15 AM
On a fresh installation of a test forum on your hosting with no other mods or themes installed does the same thing happen? If it does we will know it is a hosting issue...if not then you may have a corrupt file or a mod conflict.

In the latter case you might consider replacing the files of your forum with fresh versions...it's not a difficult process. You would backup your files and your database before you begin then delete all files and directories that are in the SMF installation pack (meaning that you would keep such things as a Gallery directory or a Games directory that aren't in the pack but may have been added by some of the mods you may use) save for Settings.php and Settings_bak.php in your forum root. Replace all these files and directories with fresh copies taken from the SMF installation pack (again excluding the afore mentioned files) and then add the Bookmark mod again...check that it works properly...if so then slowly add other mods and themes checking at each stage to see that the mod still works properly.

This file replacement won't affect your stored records in your database so no postings will be lost (and in any event you will have your backups.)
Title: Re: Bookmark Mod
Post by: johny000 on July 19, 2007, 01:15:38 AM
hello everyone
i have Dilber Multicolor theme by HarzeM
& i add the mod but is not Display  i cant see the My Bookmark  by the menu why ?  can any one help
Title: Re: Bookmark Mod
Post by: TrueSatan on July 19, 2007, 08:48:38 PM
Yours is a custom theme and like almost all mods this mod only installs into the SMF default theme. You need to do a manual installation into any custom theme. Herewith a link to the official SMF documentation giving details of how to do it:

http://docs.simplemachines.org/index.php?topic=402.msg531#msg531 (http://docs.simplemachines.org/index.php?topic=402.msg531#msg531)

You may also find the following link helpful:

http://modparser.dev.dansoftaustralia.net/ (http://modparser.dev.dansoftaustralia.net/)
Title: Re: Bookmark Mod
Post by: johny000 on July 23, 2007, 06:31:16 PM
hello everyone  & thank you TrueSatan 
but soorry the link you give me  did not  help me

note for ppl using Dilber Multicolor theme by HarzeM. this code

    // The [bookmarks] button
if ($context['user']['is_logged'])
echo ($current_action == 'bookmarks' || $context['browser']['is_ie4']) ? '<td class="maintab_active_' . $first . '">&nbsp;</td>' : '' , '
<td valign="top" class="maintab_' , $current_action == 'bookmarks' ? 'active_back' : 'back' , '">
<a href="', $scripturl, '?action=bookmarks">' , $txt['bookmarks'] , '</a>
</td>' , $current_action == 'bookmarks' ? '<td class="maintab_active_' . $last . '">&nbsp;</td>' : '';

  is not working 100% with the Dilber Multicolor theme by HarzeM.

iwas playng with code & i fix it.  use this code 
    // The [bookmarks] button
if ($context['user']['is_logged'])
echo ($current_action == 'bookmarks' || $context['browser']['is_ie4']) ? '<td class="menubg' . $first . '">&nbsp;</td>' : '' , '
<td align="center" class="menubg' , $current_action == 'bookmarks' ? 'active_back' : 'back' , '">
<a href="', $scripturl, '?action=bookmarks">' , $txt['bookmarks'] , '</a>
</td>' , $current_action == 'bookmarks' ? '<td class="menubg' . $last . '"></td>' : '';

Title: Re: Bookmark Mod
Post by: Scarlet Tree on August 09, 2007, 08:12:17 AM
Hi, I just installed this mod, but I can't figure out how to add the following code in my not default Display.template file:

$normal_buttons = array(
'reply' => array('test' => 'can_reply', 'text' => 146, 'image' => 'reply.gif', 'lang' => true, 'url' => $scripturl . '?action=post;topic=' . $context['current_topic'] . '.' . $context['start'] . ';num_replies=' . $context['num_replies']),
'bookmark' => array('text' => 'bookmark_add', 'lang' => true, 'url' => $scripturl . '?action=bookmarks;sa=add;topic=' . $context['current_topic']),


I'm using Pn-Pn 1.1.3 as theme, which contains this part of code and uses images as buttons:

$buttonArray = array();
if ($context['can_reply'])
$buttonArray[] = '<a href="' . $scripturl . '?action=post;topic=' . $context['current_topic'] . '.' . $context['start'] . ';num_replies=' . $context['num_replies'] . '">' . ($settings['use_image_buttons'] ? '<img src="' . $settings['images_url'] . '/' . $context['user']['language'] . '/reply.gif" alt="' . $txt[146] . '" border="0" />' : $txt[146]) . '</a>';
if ($context['can_mark_notify'])


Someone knows how to change the code here? Thanks.

edit: nevermind, I worked out this code to bookmark with an image (bookmark.gif):

if ($context['can_reply'])
$buttonArray[] = '<a href="' . $scripturl . '?action=bookmarks;sa=add;topic=' . $context['current_topic'] . '.">' . ($settings['use_image_buttons'] ? '<img src="' . $settings['images_url'] . '/' . $context['user']['language'] . '/bookmark.gif" alt="' . '" border="0" />' : $txt['bookmark_add']) . '</a>';


:)
Title: Re: Bookmark Mod
Post by: ragots on August 30, 2007, 01:41:06 AM
My forum is embedded in Joomla. After the user delete a bookmark the forum goes back to standalone.  I don't want my users to ever see the standalone version.

Where do I fix that ? Which file do I modify and what ?


Thanks
Title: Re: Bookmark Mod
Post by: TrueSatan on August 30, 2007, 07:06:49 AM
@ ragots

Given that the Joomla/SMF bridge is now discontinued I'm unable to replicate your configuration to see what is going wrong. I can't be of any help on this issue and can only suggest that as you will have so abandon the bridge in order to upgrade your software in any case it is the least of your forum problems.
Title: Re: Bookmark Mod
Post by: Leipe Po on November 22, 2007, 09:02:10 AM
well it wasnt likely to come back, but i'm back!!!
i worked on some projects in other programming languages, now thats all done,
and i bought a house so was busy with that, plus promotion at work consumed alot of my time,
now everything is in place i have some more free time so i can work on my hobby's some more,
when ive got my website up and running i will release a new bookmark mod for 1.1.4, till that time i would like a list of features you all would like to see in it,

and by the way, i live in the netherlands, never been to the UK or china  ;)
and this mod has no licence, i like to call it "Public Domain", that means you are free to use/modify/release it, if you want to give credit, be my guest, but i would never demand it...
Title: Re: Bookmark Mod
Post by: TrueSatan on November 22, 2007, 10:35:54 AM
Welcome back...I've done a tidy up of your code and bug fixes as has Karl Benson...we have a working SMF 1.1.4 version already (1.1.x actually) and I have been making it available via the SMF Helper site (link in my signature.)

If you'd like the code it's available to download there and I'll happily hand the future development of it back to you (or share it with you) though I would suggest that you review the other bookmarks mod now available for SMF.

Please let me know (via PM) if I can be of further assistance.
Title: Re: Bookmark Mod
Post by: BigMike on February 27, 2008, 10:51:55 AM
Quote from: TrueSatan on November 22, 2007, 10:35:54 AM
and I have been making it available via the SMF Helper site (link in my signature.)

I searched your site and could not find it. Could you provide a direct link for it?

(or any direct link for a version of this mod that works with 1.1.4?)

Thanks!
BigMike
Title: Re: Bookmark Mod
Post by: RoCKeT-88 on April 14, 2008, 08:58:13 PM
Leipe Po are you still gonna update this to 1.4.1?  I am either a.) too stupid figure out the errors with the other bookmark mod or b.) too stupid to figure out the other one. ;)

Thanks!
Title: Re: Bookmark Mod
Post by: thedesigner on March 08, 2009, 01:34:32 PM
I got a few test failed errors when trying to install this bookmark mod. Any suggestions? Im using a custom theme. Test failed on two files, board index and manage permissions.  :'(
Title: Re: Bookmark Mod
Post by: maelstr0m on May 10, 2009, 08:08:47 PM
Does this work with SMF 1.1.7 and/or a non-default theme such as Dilber Multicolor? I encounter the following errors upon installation:

Execute Modification   ./Themes/default/Display.template.php   Test failed
Execute Modification   ./index.php   Test failed
Title: Re: Bookmark Mod
Post by: Karmalakas on February 06, 2012, 02:21:06 PM
Any chances this would be upgraded to SMF 2.0?
Title: Re: Bookmark Mod
Post by: Kindred on February 06, 2012, 02:27:22 PM
search is your friend...  http://custom.simplemachines.org/mods/index.php?mod=864
Title: Re: Bookmark Mod
Post by: Karmalakas on February 06, 2012, 03:32:35 PM
I saw that one, bus authors aren't the same. I had mod by Leipe Po in my SMF 1.1 and after upgrading to 2.0 I want it to work the same. Sorry if I confused You.
Title: Re: Bookmark Mod
Post by: Kindred on February 06, 2012, 03:43:25 PM
Since Leipe:
Last Active:
    December 23, 2007, 03:48:29 PM

it is unlikely that this mod will ever be updated to anything...
Title: Re: Bookmark Mod
Post by: richardwbb on June 05, 2017, 10:55:11 AM
Hello there,

Leipe Po, or someone else possibly;

Is is just me or is this mod not able to bookmark a specfic 'page' within a [long] topic within an smf forum. Or is it maybe I just don't get. Just wondering, I wasn't able to implement what I sense, my users need; bookmarking a specific page within a topic, for example, not page one, but, two, or three, etc.
Title: Re: Bookmark Mod
Post by: richardwbb on June 06, 2017, 07:53:22 PM
I've figured with a given tip, that users should use the bookmark system of their browsers, well, as far as I can tell, they don't. Many knowledge about our cars [same brand model] is there and smf search isn't very helpful [my forum isn't also in decent chapters like this one is]

But I formulated an answer, asking for a mod, if it is good and looking for a 'hello world' how to make a smf package, here is the url;

Re: Bookmark (https://www.simplemachines.org/community/index.php?topic=182923.msg3930144#msg3930144)