Using mutiple instances of the module
11 posts
• Page 1 of 2 • 1, 2
Using mutiple instances of the module
Hi all,
There was another post on this matter but it doesn't answer my question.
I wanted to use a couple of instances of this module, and I did the regular procedure of renaming the relevant files, updating the .xml file, installing the module and so forth.
When I enable the module, my site just goes blank (i.e. white screen, no text, so nothing to debug with).
Any suggestions? Am I missing something?
I just renamed the files by putting a 2 at the end, and its installed as mod_filterednews2 - all the files are visible via FTP and permissions appear OK. Assume I've missed something!
Ruth
There was another post on this matter but it doesn't answer my question.
I wanted to use a couple of instances of this module, and I did the regular procedure of renaming the relevant files, updating the .xml file, installing the module and so forth.
When I enable the module, my site just goes blank (i.e. white screen, no text, so nothing to debug with).
Any suggestions? Am I missing something?
I just renamed the files by putting a 2 at the end, and its installed as mod_filterednews2 - all the files are visible via FTP and permissions appear OK. Assume I've missed something!
Ruth
- Waterbaby999
- Fresh Boarder

- Posts: 13
- Joined: Wed Apr 15, 2009 7:15 pm
Re: Using mutiple instances of the module
Hi!
Why don't you copy the module the easy way by going to your Module Manager, selecting Filtered News and clicking on Copy from the top menu?
Why don't you copy the module the easy way by going to your Module Manager, selecting Filtered News and clicking on Copy from the top menu?
-

chus - Administrator

- Posts: 455
- Joined: Thu Sep 13, 2007 2:21 am
- Location: Costa Rica
Re: Using mutiple instances of the module
Because I want to completely change the styling of the second instance - I don't think you can do that by using the method you describe, as this simply uses the same module settings in another location.
Unless of course someone can make me feel like a fewl and point out the obvious, question still stands
Ruth
Unless of course someone can make me feel like a fewl and point out the obvious, question still stands
Ruth
- Waterbaby999
- Fresh Boarder

- Posts: 13
- Joined: Wed Apr 15, 2009 7:15 pm
Re: Using mutiple instances of the module
You can have indeed different settings for each copy of a module.
-

chus - Administrator

- Posts: 455
- Joined: Thu Sep 13, 2007 2:21 am
- Location: Costa Rica
Re: Using mutiple instances of the module
I am not talking about the module settings - I want to completely change the layout, the CSS styling, the icons used for bullet points - in fact one module needs to be an ordered list.
As far as I am aware, that is not possible when simply creating a new module by going New>choose module type as it's calling from the same CSS files etc, so if I changed these it would affect all modules which are using that css file. I don't want that to happen!
I want each instance of the module to be completely different in terms of its layout and CSS styling - the only way I know of doing this is by copying the module installer and renaming it so it's a totally different folder in the "modules" folder and hence allows you to change the styling/layout without altering the first instance.
Hope that makes sense, still no closer to figuring out the random blank pages though, sure it's something I've overlooked.
Ruth
As far as I am aware, that is not possible when simply creating a new module by going New>choose module type as it's calling from the same CSS files etc, so if I changed these it would affect all modules which are using that css file. I don't want that to happen!
I want each instance of the module to be completely different in terms of its layout and CSS styling - the only way I know of doing this is by copying the module installer and renaming it so it's a totally different folder in the "modules" folder and hence allows you to change the styling/layout without altering the first instance.
Hope that makes sense, still no closer to figuring out the random blank pages though, sure it's something I've overlooked.
Ruth
- Waterbaby999
- Fresh Boarder

- Posts: 13
- Joined: Wed Apr 15, 2009 7:15 pm
Re: Using mutiple instances of the module
In that case you need to rename mod_filterednews.php and mod_filterednews.xml and change the corresponding file names in mod_filterednews.xml. Then you also need to rename the modFilteredNewsHelper class everywhere it appears in mod_filterednews.php and helper.php.
-

chus - Administrator

- Posts: 455
- Joined: Thu Sep 13, 2007 2:21 am
- Location: Costa Rica
Re: Using mutiple instances of the module
Ahh ok I did all the bits except the latter - that might well be where it is breaking things. Will give it a try this evening and get back to you 
Ruth
Ruth
- Waterbaby999
- Fresh Boarder

- Posts: 13
- Joined: Wed Apr 15, 2009 7:15 pm
Re: Using mutiple instances of the module
Thanks for the advice, my site now doesn't break, however it is still referencing the default.php from the original module and I can't for the life of me figure out where it's pointing from. I need to change this as I want one module to be an ordered list and the other to be bulleted.
- Waterbaby999
- Fresh Boarder

- Posts: 13
- Joined: Wed Apr 15, 2009 7:15 pm
Re: Using mutiple instances of the module
Any help with this would be greatly appreciated - I have tried troubleshooting but am getting nowhere. I've got the module installed and working fine but as I mentioned in the earlier message it's using the wrong file for default.php (using the one in the original location)
Ruth
Ruth
- Waterbaby999
- Fresh Boarder

- Posts: 13
- Joined: Wed Apr 15, 2009 7:15 pm
Re: Using mutiple instances of the module
Hi!
It must be due to mod_your-own/mod_your-own.php line 92
You problably need to change it to
It must be due to mod_your-own/mod_your-own.php line 92
- Code: Select all
require(JModuleHelper::getLayoutPath('mod_filterednews', $layout));
You problably need to change it to
- Code: Select all
require(JModuleHelper::getLayoutPath('mod_your-own', $layout));
-

chus - Administrator

- Posts: 455
- Joined: Thu Sep 13, 2007 2:21 am
- Location: Costa Rica
11 posts
• Page 1 of 2 • 1, 2
Who is online
Users browsing this forum: No registered users and 1 guest