Montego Scripts: Forums
 

 

View next topic
View previous topic
Post new topic   Reply to topic
Author Message
floppy
Newbie
Newbie



Joined: Sep 11, 2006
Posts: 92

PostPosted: Thu Nov 30, 2006 8:43 pm Reply with quote

I have a digital shop module and to delete a client the author said if tapped add

Code:
$next_gen_ob = 0;


below <?php

I am guessing this means to switch off. Well anyway that doesn't work, but I thought maybe yours was different and while I haven't even looked yet, I thought I would ask.
 
View user's profile Send private message Visit poster's website AIM Address Yahoo Messenger MSN Messenger
montego
Site Admin/Owner
Site Admin/Owner



Joined: Feb 12, 2005
Posts: 1399

PostPosted: Thu Nov 30, 2006 10:49 pm Reply with quote

I don't understand why this would be necessary. Just don't create a GT or GTB file for this module. Let me know which link is not working and I'll try and help you out.

Setting $next_gen_ob = 0; will do nothing for you in ShortLinks.

_________________
“To err is human, but when the eraser wears out ahead of the pencil, you’re overdoing it.”
-- Josh Jenkins 
View user's profile Send private message Visit poster's website
floppy
Newbie
Newbie



Joined: Sep 11, 2006
Posts: 92

PostPosted: Sat Dec 02, 2006 12:58 pm Reply with quote

While your suggestion worked. Its not deleting the client from the db. I am gonna have to maul it over and see what the problem is.

I used the link itself and I had the same problem.
 
View user's profile Send private message Visit poster's website AIM Address Yahoo Messenger MSN Messenger
floppy
Newbie
Newbie



Joined: Sep 11, 2006
Posts: 92

PostPosted: Sat Dec 02, 2006 1:02 pm Reply with quote

Here is that part of the script.

Code:
if ($_GET['delete'] == 1) {
   
   OpenTable();
   if ($db->sql_query("DELETE FROM ".$prefix."_digital_clients WHERE client_id='".$_GET['cid']."'")) {
      echo "<center><font color='red'>Client deleted successfully!</font></center>";
   } else {
      echo "<center><font color='red'>Unable to delete client!</font></center>";
   }
   CloseTable();
   echo "<br>";
   
}


It says client deleted successfully, but nada is happening in the db.
 
View user's profile Send private message Visit poster's website AIM Address Yahoo Messenger MSN Messenger
montego
Site Admin/Owner
Site Admin/Owner



Joined: Feb 12, 2005
Posts: 1399

PostPosted: Sat Dec 02, 2006 2:15 pm Reply with quote

Here is what I suggested floppy do:

Try hard-coding the following line:

Code:

    window.location='".$admin_file.".php?&op=digi_clients&delete=1&id=$cid';


Make it look something like this:

Code:

window.location = '"digiclients-admin-delete-".$cid."';


Then, add to your .htaccess the following rule:

Code:
 
RewriteRule ^digiclients-admin-delete-([0-9]*).html admin.php?op=digi_clients&delete=1&id=$1 [L]


I've had to do something similar with some other modules and thought I'd mention it here in case it would help someone else with the concept anyways.

_________________
“To err is human, but when the eraser wears out ahead of the pencil, you’re overdoing it.”
-- Josh Jenkins 
View user's profile Send private message Visit poster's website
montego
Site Admin/Owner
Site Admin/Owner



Joined: Feb 12, 2005
Posts: 1399

PostPosted: Sat Dec 02, 2006 2:17 pm Reply with quote

Floppy, you may want to echo out $_GET['cid'] so see if it is getting valued.

What does your link look like once tapped?

_________________
“To err is human, but when the eraser wears out ahead of the pencil, you’re overdoing it.”
-- Josh Jenkins 
View user's profile Send private message Visit poster's website
floppy
Newbie
Newbie



Joined: Sep 11, 2006
Posts: 92

PostPosted: Fri Dec 08, 2006 9:28 pm Reply with quote

I think my link is correct. As that appears to be the right id.
Code:
digiclients-admin-delete-1.html
 
View user's profile Send private message Visit poster's website AIM Address Yahoo Messenger MSN Messenger
montego
Site Admin/Owner
Site Admin/Owner



Joined: Feb 12, 2005
Posts: 1399

PostPosted: Sat Dec 09, 2006 10:15 am Reply with quote

montego wrote:
Floppy, you may want to echo out $_GET['cid'] so see if it is getting valued.


??

_________________
“To err is human, but when the eraser wears out ahead of the pencil, you’re overdoing it.”
-- Josh Jenkins 
View user's profile Send private message Visit poster's website
floppy
Newbie
Newbie



Joined: Sep 11, 2006
Posts: 92

PostPosted: Sat Dec 09, 2006 4:09 pm Reply with quote

Hmm.. your right. I did a little test and just added $cid to the success message and it keeps retuning blank.

Code:
Clients deleted Successfully $cid


Is returning as

Code:
Clients deleted Successfully


I am gonna poke at it and see whats up.

Thanks,
 
View user's profile Send private message Visit poster's website AIM Address Yahoo Messenger MSN Messenger
montego
Site Admin/Owner
Site Admin/Owner



Joined: Feb 12, 2005
Posts: 1399

PostPosted: Sat Dec 09, 2006 4:59 pm Reply with quote

If the code you have above is inside a function, make sure $cid is in a global statement right below the function definition.

_________________
“To err is human, but when the eraser wears out ahead of the pencil, you’re overdoing it.”
-- Josh Jenkins 
View user's profile Send private message Visit poster's website
montego
Site Admin/Owner
Site Admin/Owner



Joined: Feb 12, 2005
Posts: 1399

PostPosted: Sat Dec 09, 2006 5:01 pm Reply with quote

Guardian just posted his E-Solutions tap in the "Additional Taps" forum. Is this the same module as what you have?

_________________
“To err is human, but when the eraser wears out ahead of the pencil, you’re overdoing it.”
-- Josh Jenkins 
View user's profile Send private message Visit poster's website
floppy
Newbie
Newbie



Joined: Sep 11, 2006
Posts: 92

PostPosted: Sat Dec 09, 2006 5:16 pm Reply with quote

No this is for digital shop from www.nukecoder.com

http://clan-themes.co.uk/shop.html

I modded this to allow multiple authors and use different currencys for each along with thier paypal account.

Just trying to tidy up the admin. I doubt any of my mods have anything to do with it since I never cam close or related to this clients section yet Very Happy
 
View user's profile Send private message Visit poster's website AIM Address Yahoo Messenger MSN Messenger
Guardian
Site Admin
Site Admin



Joined: Jul 18, 2005
Posts: 397

PostPosted: Sat Dec 09, 2006 9:23 pm Reply with quote

Thanks for that floppy, I knew Laurentius was working on a Digital Shop as a lot of the code was already in E-Solution (but commented out) but the site you have linked to is not one of his offerings so I might check it out.
 
View user's profile Send private message
Display posts from previous:       
Post new topic   Reply to topic

View next topic
View previous topic
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001-2007 phpBB Group
All times are GMT - 4 Hours
 
Forums ©
linear-bunchlinear-bunch