TOPIC:

Contest - Enter Once a Day 3 years 2 months ago #203957

  • Topic Author
  • EquineInfoEx
  • Offline
  • Fresh Breezer
  • Fresh Breezer
  • Posts: 10
  • Thanks: 0
updated the code
if($ipDb == $ip) {
header("Location: www.equine-info.com/devsite/index.php/ho...s/533-sign-up-to-win ");
exit;
}

got this new error
This page isn’t working

www.equine-info.com redirected you too many times.

Please Log in or Create an account to join the conversation.

Contest - Enter Once a Day 3 years 2 months ago #203958

  • tomeperica's Avatar
  • tomeperica
  • Offline
  • User is blocked
  • User is blocked
  • Posts: 6478
  • Karma: 170
  • Thanks: 667
It will create a new record I think, you will get a new information in subrecords table.

Can you pls remove this from code:

$db->execute();

and then test again.

ALso check the Integrator tutorial about inserting new stuff: crosstec.org/en/component/finder/search....rator&f=1&Itemid=146

Let me know the result when you remove the code.

Regards,
Tome
Regards,
Tome
==========================================
Need to renew Pro Support?
Buy Here!
==========================================
Satisfied?
Consider a membership!
==========================================
Like us on Facebook
==========================================
Support Crosstec and get ALL EXTENSIONS and professional support for just $5
Here!

Please Log in or Create an account to join the conversation.

Contest - Enter Once a Day 3 years 2 months ago #203959

  • tomeperica's Avatar
  • tomeperica
  • Offline
  • User is blocked
  • User is blocked
  • Posts: 6478
  • Karma: 170
  • Thanks: 667
And yes sry fogot to mention to change the link for redirection, sry for that.

Regards,
Tome
Regards,
Tome
==========================================
Need to renew Pro Support?
Buy Here!
==========================================
Satisfied?
Consider a membership!
==========================================
Like us on Facebook
==========================================
Support Crosstec and get ALL EXTENSIONS and professional support for just $5
Here!

Please Log in or Create an account to join the conversation.

Contest - Enter Once a Day 2 weeks 12 hours ago #248251

  • lena11d
  • Offline
  • Fresh Breezer
  • Fresh Breezer
  • Posts: 5
  • Thanks: 0
Hello:

I tried the solution in this ticket and it did not work for some reason. All it does is redirects to the page I specified in the Location, but the submissions still go through.

Here is the code that I inserted:
$ip = $_SERVER['REMOTE_ADDR'];;
$db = JFactory::getDBO();

$sqlGetTime = 'SELECT MAX(submitted) FROM  #__facileforms_records';
$db->setQuery($sqlGetTime);
$result = $db->loadResult();
$date1 = new DateTime(date('Y-m-d', strtotime($result)));
$date2 = new DateTime(date('Y-m-d', strtotime("now")));
$dayDiff = $date1->diff($date2)->days;
if($dayDiff > 0) {
    $db->setQuery("Delete From #__facileforms_records Where ip ='".$ip."' and form = 114");
    
}
$db->setQuery("Select ip From #__facileforms_records Where ip ='".$ip."' and form = 114");
$ipDb = $db->loadResult();
if($ipDb == $ip) {
    header("Location: https://www.mysite.com/redirect-page");
    exit;
}

Is there something that Im doing wrong?

Thank you
Lena

Please Log in or Create an account to join the conversation.

Contest - Enter Once a Day 1 week 6 days ago #248286

  • TheMuffinMan's Avatar
  • TheMuffinMan
  • Offline
  • Developer
  • Developer
  • Posts: 10063
  • Karma: 167
  • Thanks: 800
Hi,

it sounds like you were adding this in an end submit piece, which would explain your observation as it would delete the previous, store the new one and redirect.

Please try to use the code instead in form => advanced => more options => form pieces => before form => custom.

Regards,
Markus

Please Log in or Create an account to join the conversation.

Contest - Enter Once a Day 1 week 6 days ago #248291

  • lena11d
  • Offline
  • Fresh Breezer
  • Fresh Breezer
  • Posts: 5
  • Thanks: 0
Hello:

Just double checked. I believe I have it in the right place, please see the attached. The only only other script I have is Scripts - > Submitted scripts - > showsubmitted

Also last time I tested this form was a few days ago. Now every time I try to go to this page with the form - it redirects me to the page that is supposed to be showing up after submission. So kind of looks like my IP is blocked for more than 24 hours?

Thank you
Lena
Attachments:

Please Log in or Create an account to join the conversation.

Moderators: ForumSupport
Time to create page: 0.045 seconds

BreezingForms Pro 1.4.7 for WordPress Released!

Available in the membership section.

September Discount!

Massive discounts on all subscriptions!

Get Your Subscription Here

Quick Links

Downloads

BreezingForms

ContentBuilder

BreezingCommerce

Templates

Documentation

BreezingForms

ContentBuilder

BreezingCommerce

Apprendre BreezingForms (French Community)

Apprendre et maîtriser BreezingForms par des tutoriels et exemples, le tout en français

breezingforms.eddy-vh.com

Questions et réponses sur les forums de l'AFUJ

AFUJ

Special Offer

Summer Sale! All subscriptions at a special price!

Includes prio support, all of our current and future Joomla!® extensions and Joomla!® templates for the duration of your membership.

Get it from here

3rd Party Discount - 25% Off

We help you to keep your costs under control. If you are a new member and purchased a form building tool from a different form vendor, then you'll get a 25% discount on our subscription plans.

How to receive the discount:

Send us a quick email to sales@crosstec.org with a proof of purchase (for example a paypal receipt), await payment instructions and enjoy your membership!