81
Xman04
Re: How do I prevent linked site pages from opening in a new window?
  • 2006/5/24 2:40

  • Xman04

  • Not too shy to talk

  • Posts: 180

  • Since: 2004/7/12


The module.textsanitizer.php file is definitely the key. It adds the target=_blank command to some of the generated URLs within the XOOPS system.

I was able to stop the notification messages from opening in a new window, by changing one of the many target=_blank codes to target=_self.

Anyway, just wanted to let everyone know. It took me a long time to locate the source of this issue, and hopefully I can save others from spending so much time on it.

Dave



82
Xman04
Re: How do I prevent linked site pages from opening in a new window?
  • 2006/5/23 15:04

  • Xman04

  • Not too shy to talk

  • Posts: 180

  • Since: 2004/7/12


This is getting very frustrating. I've searched all over the forum posts and don't see anything even remotely close to addressing this issue.

I'm even having trouble finding the files where the following template variables are originally defined:

X_UNAME
STORY_NAME
X_SITENAME
STORY_URL
X_UNSUBSCRIBE_URL

Maybe I'm just tired and I'm missing where those are defined. However, I've looked through many files.

I'm going to play around with the module.textsanitizer.php file, and try changing many of the target="_blank" entries to target="_self". I'm not a PHP programmer, and don't quite know what many of the patterns/replacements are referring to. However, maybe if I test one at a time I will get lucky and find one that resolves this (if the resolution is contained in that file). Or maybe, there is something that I can add to the template itself. Although, I've tried that already without success.

At this point, I'm out of ideas and don't know what else could be generating the target="_blank" behavior for these templates.

If anyone has any ideas or can send me in the right direction, I would much appreciate it.

Dave



83
Xman04
Re: How do I prevent linked site pages from opening in a new window?
  • 2006/5/22 20:44

  • Xman04

  • Not too shy to talk

  • Posts: 180

  • Since: 2004/7/12


Hi,

I found the templates that the notifications use. The templates are in the mail templates of the language folders of each module. The templates include unchanging text and embedded smarty tags to fill in stuff such as the article URL, user name, site URL, etc.

Obviously, the smarty tags are converted into URLs for the user to click on. I'm still trying to figure out where to stop the rendered URLS from including target="_blank" in their source HTML. I want them to include target="_self", so that the clicked on links open the pages within the same browser window (not open a new window). I looked at module.textsanitizer.php to see if I could change it there, but I don't see any reference to these specific tags (unless I missed it).

Where do I replace target="_blank" with target="_self" for the smarty tags included in the sample template below?

Quote:


Hello {X_UNAME},

A new story "{STORY_NAME}" has been added at {X_SITENAME}.

You can view this story here:
{STORY_URL}

-----------

You are receiving this message because you selected to be notified when new stories are added to our site.

If this is an error or you wish not to receive further such notifications, please update your subscriptions by visiting the link below:
{X_UNSUBSCRIBE_URL}

Please do not reply to this message.

-----------

{X_SITENAME} ({X_SITEURL})
webmaster
{X_ADMINMAIL}



84
Xman04
How do I prevent linked site pages from opening in a new window?
  • 2006/5/20 22:34

  • Xman04

  • Not too shy to talk

  • Posts: 180

  • Since: 2004/7/12


Hi,

When a user opens a notification's message, the following message format appears:

Quote:
Hello ......,

A new article "............" has been added at ........com.

You can view this article here:
http://www......com/modules/..../article.php?storyid=14

-----------

You are receiving this message because you selected to be notified when new articles are added to our site.

If this is an error or you wish not to receive further such notifications, please update your subscriptions by visiting the link below:
http://www........com/notifications.php

Please do not reply to this message.

etc, etc.


The problem is that when the article or notifications links are clicked, the article page or notification settings page opens up in a new browser window. I would like them to open within the same window, since I really don't think it should behave like a popup screen (especially since it is linking pages within the site). I've noticed this same issue when I place url links in custom blocks. Where would I change this?

From what I see in the rendered html, it looks like target_blank is being added to the url, which causes it to open in a new window (if I remember correctly).



85
Xman04
Re: Notifications error - *Serious*
  • 2006/5/6 6:03

  • Xman04

  • Not too shy to talk

  • Posts: 180

  • Since: 2004/7/12


Hi,

I went to the Smart Factory site and found the solution to the smartsection end of the problem.

Here is the solution

Open the file smartsection/include/notification.inc.php and look for line (12), which is the following:

Quote:
global $xoopsModule, $xoopsModuleConfig, $xoopsConfig;


Add the following after line 12:

Quote:
include_once(XOOPS_ROOT_PATH . "/modules/smartsection/include/seo_functions.php");

**The above should be one line. The narrow margins of this post may incorrectly show it as more than one line.


If you don't use News 1.44, then this should fix your entire problem. I also use News 1.44, and I'm still receiving the following error message.

Quote:
Notice [PHP]: Undefined offset: 1 in file modules/news/include/notification.inc.php line 38


However, this isn't a really big problem, since the error message doesn't show up once the PHP debugging is turned off. It would still be nice to resolve it, but I'm not going to lose any sleep over it. There are a few other issues though with the notifications system, but I may save them for another post, since they don't seem directly related to the above errors.

Dave



86
Xman04
Re: Notifications error - *Serious*
  • 2006/5/5 2:57

  • Xman04

  • Not too shy to talk

  • Posts: 180

  • Since: 2004/7/12


Ok, now this really makes no sense. I told my partner about the problem, and she logged in and could not duplicate the error. Her notifications page worked fine.

I made a new account for myself, with all of the same settings of my original master account. The new account did not generate the errors, but my original account still generated the errors even with the same exact settings.

The only difference between the two accounts was that articles were posted under the account that generated the errors. Well, I tried posting some articles under the new account name, and then the error starting appearing under that account name too. To make matters more confusing, the errors do not go away even after I delete the articles. In fact, the error occurs even while posting or modifying a News 1.44 article, not just when I click on notifications in the user menu.

Thus, there is some problem with the notifications system that only appears after at least one article is initially posted. I'm not sure if this is a problem specifically with smartsection or News 1.44, or if it is a problem in the system core. The error messages so far are only specific to News 1.44 and Smartsection.

Anyway, this problem appears to be a very serious one. I don't think I can open my site to the public until it is resolved. Any ideas about this?

Dave



87
Xman04
Notifications error
  • 2006/5/4 20:37

  • Xman04

  • Not too shy to talk

  • Posts: 180

  • Since: 2004/7/12


Hi,

When I click on "Notifications" under my User menu on the home page, I receive a blank page and the following errors:

Quote:
Fatal error: Call to undefined function: smartsection_seo_genurl() in /home/...../public_html/modules/smartsection/include/notification.inc.php on line 48

Notice [PHP]: Undefined offset: 1 in file modules/news/include/notification.inc.php line 38


I'm not sure when the source of this problem started, since I clicked on notifications for the first time in quite a while. The site isn't open to the public yet.

I did a search here, but couldn't find any solutions to this error. I few other people have mentioned a similar problem.

Does anyone know of a solution to this or why it is occurring? My XOOPS version is 2.0.13.2

Dave



88
Xman04
Re: Internet Explorer Error
  • 2006/4/30 4:51

  • Xman04

  • Not too shy to talk

  • Posts: 180

  • Since: 2004/7/12


Hi,

The XOOPS version is 2.0.13.2. The specific theme doesn't seem to matter, since it has occurred in different themes.

I cannot consistency cause the error message to appear. It seems to occur more often during some login sessions than others. I'm not sure what initially triggers it, since it seems quite random.

Maybe it is more of an Internet Explorer problem than XOOPS problem, especially since I've not yet noticed it in Firefox. It has been occurring more often since I installed additional modules.

Dave



89
Xman04
Internet Explorer Error
  • 2006/4/29 21:12

  • Xman04

  • Not too shy to talk

  • Posts: 180

  • Since: 2004/7/12


Hi,

I often receive an error message on the bottom bar of the Internet Explorer browser window while in the main administration area or in a module administration area. This error message does not occur in Firefox

This is the error message:

Line: 26
Char: 3
Error: Object Required
Code: 0
URL: Gives the url of the current page

I don't receive this error in the actual pages that the users would see, but only in administrative sections. The error does not always occur. Has anyone else experienced this error? Any ideas what is causing it? Is it anything to worry about? Everything seems to function correctly, even with that error message.

Dave



90
Xman04
Re: MultiMenu Caption Popups - how to turn off?
  • 2006/4/20 8:51

  • Xman04

  • Not too shy to talk

  • Posts: 180

  • Since: 2004/7/12


Hi Blueteen,

Thank you for the information. I added {alt} to each menu option title, and that worked.

Dave




TopTop
« 1 ... 6 7 8 (9) 10 11 12 ... 16 »



Login

Who's Online

120 user(s) are online (61 user(s) are browsing Support Forums)


Members: 0


Guests: 120


more...

Donat-O-Meter

Stats
Goal: $100.00
Due Date: May 31
Gross Amount: $0.00
Net Balance: $0.00
Left to go: $100.00
Make donations with PayPal!

Latest GitHub Commits