351
Mazarin
Re: Accessing xoopsModuleConfig from a block
  • 2009/10/14 21:15

  • Mazarin

  • Just can't stay away

  • Posts: 533

  • Since: 2008/12/10


Let's take a step back and answer some fundamentals first:
The way you describe it, can you call module parameters without having it as the "active" module, i.e. from a block or a different module?

I don't think there's anything wrong with the code per se. I have changed very little and it does work with the xoopspoll module.

Regarding the code posted in this thread, I get an error for a function call on a non-object (the getVar).



352
Mazarin
Re: Accessing xoopsModuleConfig from a block
  • 2009/10/14 19:57

  • Mazarin

  • Just can't stay away

  • Posts: 533

  • Since: 2008/12/10


But it doesn't. I'm sure that there is some fundamental mistake I'm doing or some concept I haven't grasped.

I'm calling a static function in a class (in a separate file) from the block show function. The static function called then declares global $xoopsModuleConfig and uses that to get the $xoopsModuleConfig['limit_by_uid'] .

Now, why does it work when showing the block together with the module, but not when showing it together with other modules? To me it seems like it is dependent on something being initiated (or to that effect), which it isn't when calling just the static function.

Is it so that you can only call parameters using the global $xoopsModuleConfig from the "active" module? (makes sense now that I think about it)

Is this what your code above is trying to circumvent (though it doesn't work for me)?



353
Mazarin
Re: Accessing xoopsModuleConfig from a block
  • 2009/10/14 19:02

  • Mazarin

  • Just can't stay away

  • Posts: 533

  • Since: 2008/12/10


Thx for the help, but unfortunately it didn't work.

The key here is why it works from within the module and when the block is displayed together with the module, but not when the block is displayed together with other modules.

(The module is XoopsPoll and the parameter I'm trying to get is limit_by_id and limit_by_ip)



354
Mazarin
Re: UserPage Problems
  • 2009/10/12 7:25

  • Mazarin

  • Just can't stay away

  • Posts: 533

  • Since: 2008/12/10


What does the error log say?



355
Mazarin
Re: Accessing xoopsModuleConfig from a block
  • 2009/10/12 6:28

  • Mazarin

  • Just can't stay away

  • Posts: 533

  • Since: 2008/12/10


Just this warning:
Warning: xoopsOption[template_main] should be defined before including header.php in file /footer.php line 68

I haven't done anything to those files, so I assume this has nothing to do with my problem?



356
Mazarin
Accessing xoopsModuleConfig from a block
  • 2009/10/11 20:17

  • Mazarin

  • Just can't stay away

  • Posts: 533

  • Since: 2008/12/10


I use 2.3.2 and am trying to access xoopsModuleConfig from a block to get some preferences for a module. Unfortunately it doesn't seem to work as I don't get any values, so I'm wondering if there are any obvious things when calling xoopsModuleConfig that I'm missing here?

I'm calling them through a static function in a module and the function works and gets called. I've checked the db and the values are there. It works perfectly fine when I try to access them through the actual module, but not from the block.

I know I could just make my own call to the db, but I might as well use what's built into XOOPS if possible.



357
Mazarin
Re: 2.4 RC user registration fails, blanc screen
  • 2009/10/9 11:28

  • Mazarin

  • Just can't stay away

  • Posts: 533

  • Since: 2008/12/10


And the solution (and cause of the problem) was?

I'm very interested since I have experienced problems with registering users through 2.3.2, 2.3.3 and 2.4.0



358
Mazarin
Re: xoops chat integration (like facebook) ?
  • 2009/10/7 6:17

  • Mazarin

  • Just can't stay away

  • Posts: 533

  • Since: 2008/12/10


That would be an awesome feature



359
Mazarin
Re: theme framework
  • 2009/10/2 11:37

  • Mazarin

  • Just can't stay away

  • Posts: 533

  • Since: 2008/12/10


Any progress?



360
Mazarin
Re: redirecting existing users to complete their profiles
  • 2009/10/2 11:29

  • Mazarin

  • Just can't stay away

  • Posts: 533

  • Since: 2008/12/10


I think those two are just different versions of the same problem. I would guess what is required is a hack in the user.php file that includes a simple query to the user table in the db and then a check to see if a field/number of fields are filled out, if yes->proceed, if not->redirect to edituser.php.

Hmmm, thinking about it, I might do this to one of my own sites when I have the time. Shouldn't take long to do it (unless I am wrong of course, but then I hope someone corrects me in this thread )




TopTop
« 1 ... 33 34 35 (36) 37 38 39 ... 44 »



Login

Who's Online

193 user(s) are online (132 user(s) are browsing Support Forums)


Members: 0


Guests: 193


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