DragonPrime - LoGD Resource Community
Welcome Guest
  • Good evening, Guest.
    Please log in, or register.
  • September 25, 2017, 08:52:26 PM
Home Forums News Downloads Login Register Advanced Search
* * *
DragonPrime Menu
Login
 
 
Resource Pages
Search

Pages: 1 2 [3] 4 5   Go Down
  Print  
Author Topic: File Discussion: Multi Poke  (Read 9971 times)
0 Members and 1 Guest are viewing this topic.
RaynDarren
Mod God
*****
Offline Offline

Posts: 732


View Profile WWW
« Reply #30 on: November 10, 2012, 01:15:12 PM »

Aboslutely, I'm sorry.

The reason I suggested it is I'm working on a version of warriors online that'll appear in the village as a popup. ONLY the players name will be in the listing. When clicked, ONLY the pokes will be available. That restriction of pokes per day would be, at least in my opinion, necessary to prevent abuse and spamming.
Logged

Aeolus
Mod God
*****
Offline Offline

Posts: 1773


You're welcome.


View Profile WWW
« Reply #31 on: November 10, 2012, 02:28:56 PM »

If you're going to use the pokes in another popup module, you'll need to add override_forced_nav into the getmoduleinfo function of the module. As well as changing cases of page_header and page_footer to popup_header and popup_footer respectively for occurances of popup pokes. And keeping the page_ functions for pokes that are triggered from a regular bio. Good luck with it all.

I've actually made my own Warriors Online popup module based on Afkamm's Grotto Warriors Online, if you're interested in me attaching it (it hooks as a link into the charstats).
Logged

RaynDarren
Mod God
*****
Offline Offline

Posts: 732


View Profile WWW
« Reply #32 on: November 10, 2012, 02:45:33 PM »

Nods... did all that, thanks Smiley

Sure, I'd love to see yours :d.

I've gotten mine the way I like it.. so far Smiley.

I have run into a little problem though, i can't get the pokes to appear.

This is the code I've pasted from multipoke:
      addnav("$nav","runmodule.php?module=multipoke&op=$op&id={$row['id']}&char=$char&ret=$ret");


Something tells me I need more than just that, but I'm unsure what.
Logged

Aeolus
Mod God
*****
Offline Offline

Posts: 1773


You're welcome.


View Profile WWW
« Reply #33 on: November 10, 2012, 02:54:48 PM »

I've attached it. Smiley

And you can't use the addnav function in a popup window. When was the last time you saw navs in a popup window? You'll have to use a table and HTML links.

Plus, you'll have to change the 'op' and 'id' in the URL of the link so that they fit the module correctly.
« Last Edit: November 10, 2012, 02:57:11 PM by Aeolus » Logged

RaynDarren
Mod God
*****
Offline Offline

Posts: 732


View Profile WWW
« Reply #34 on: November 10, 2012, 03:01:02 PM »

Well now, don't I feel stupid!

So, this would work?
get_module_setting("$nav") "multipoke&op=$op&id={$row['id']}&char=$char&ret=$ret"

$nav = translate_inline("$nav")

      rawoutput('<hr /><a href="'.$nav.'"></a><br /><br />');

And thanks for the attachment Smiley
Logged

Aeolus
Mod God
*****
Offline Offline

Posts: 1773


You're welcome.


View Profile WWW
« Reply #35 on: November 10, 2012, 03:06:30 PM »

Well now, don't I feel stupid!

So, this would work?
get_module_setting("$nav") "multipoke&op=$op&id={$row['id']}&char=$char&ret=$ret"

$nav = translate_inline("$nav")

      rawoutput('<hr /><a href="'.$nav.'"></a><br /><br />');

And thanks for the attachment Smiley

What are you aiming to get with the get_module_setting function? I don't understand that bit.

And you're going to need text between the 'a' tags to actually have a link to click. For example: <a href="'.$nav.'">$texthere</a>, where $texthere is the name of the poke, for example.

And take note about what I said with changing the 'op' and 'id' in the link so that it fits correctly.
Logged

RaynDarren
Mod God
*****
Offline Offline

Posts: 732


View Profile WWW
« Reply #36 on: November 10, 2012, 03:12:20 PM »

I was /trying/ to pull the pokes from multipoke.

I'm now super confused Sad

rawoutput('<hr /><a href="'.$nav.'">$poketexthere</a><br /><br />');

How do I get each poke to list?
Logged

Aeolus
Mod God
*****
Offline Offline

Posts: 1773


You're welcome.


View Profile WWW
« Reply #37 on: November 10, 2012, 03:15:48 PM »

The pokes are stored in a database table, not a game setting.

You'll have to do multiple rawoutput's. Or use a for loop. The latter would be easier. I'd see if I can edit my module that I attached earlier to how you want it, but I'm not exactly sure how you'd want it laid out.
Logged

RaynDarren
Mod God
*****
Offline Offline

Posts: 732


View Profile WWW
« Reply #38 on: November 10, 2012, 03:18:12 PM »

I can't just do a db_query?

Here's my currently inprogress version.
Logged

Aeolus
Mod God
*****
Offline Offline

Posts: 1773


You're welcome.


View Profile WWW
« Reply #39 on: November 10, 2012, 04:01:25 PM »

As long as you've correctly modified the Multi-Poke module to take into account the popup window, the attached module will work for you. (The display works, I didn't bother modifying the Multi-Poke module to see if the pokes worked. Should, though.)
Logged

RaynDarren
Mod God
*****
Offline Offline

Posts: 732


View Profile WWW
« Reply #40 on: November 10, 2012, 04:11:35 PM »

Okie, so, I did that all... problem though,  the editor now appears as a popup with no return links. I'm not entirely sure what went wrong Sad.
Logged

Aeolus
Mod God
*****
Offline Offline

Posts: 1773


You're welcome.


View Profile WWW
« Reply #41 on: November 10, 2012, 04:23:23 PM »

The editor? Nothing should be wrong with the editor. You've obviously changed the page_ functions for the header and footer to popup_ functions.
Logged

RaynDarren
Mod God
*****
Offline Offline

Posts: 732


View Profile WWW
« Reply #42 on: November 10, 2012, 07:20:00 PM »

I did indeed... missed a page_footer Smiley.

So now, everything's working except that the statbar is on the popup.. I'm pretty sure that's cuz my page footer is in the wrong place, but I'm not sure where to put it.

Logged

Aeolus
Mod God
*****
Offline Offline

Posts: 1773


You're welcome.


View Profile WWW
« Reply #43 on: November 10, 2012, 07:22:09 PM »

If you wanna attach/send me your modified version of Multi-Poke, I can take a look at it for you. Smiley
Logged

RaynDarren
Mod God
*****
Offline Offline

Posts: 732


View Profile WWW
« Reply #44 on: November 10, 2012, 07:44:58 PM »

Thanks!

Problems:
1. don't know where to put the page_footer to get both the editor and popup to work correctly.
2. return link in popup takes you back to the village, so you have 2 villages open in separate windows at once.

Both files are attached in case you need them Smiley

Thank you so much!
Logged

Pages: 1 2 [3] 4 5   Go Up
  Print  
 
Jump to:  


*
DragonPrime Notices
Version 1.1.2 is the current supported version and is available for download.

Support Us
No funds raised yet this year
Your help is greatly appreciated!
Recent Topics
DragonPrime LoGD
Who's Online
33 Guests, 0 Users
Home Forums News Downloads Login Register Advanced Search