Jump to content

Search the Community

Showing results for tags 'ajax'.

More search options

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


  • The latest WHMCS Release
    • V7.9 Release Discussion
  • WHMCS Beta Program
  • The Latest from the WHMCS Team
    • News & Announcements
    • The WHMCS Blog
  • WHMCS.Community
    • Community Announcements
    • Introduce Yourself
  • Using WHMCS
    • Pre-Sales Questions
    • Admin & Configuration Questions
    • Installation, Upgrade, and Import Support
    • Using WHMCS
    • Troubleshooting Issues
    • Vendor Discussions
  • WHMCS Showcase
    • Showcase Your Site
    • Share Your Best Practices & Tips
  • Developing & Extending WHMCS
    • Third Party Add-ons
    • Service Offers & Requests
    • Developer Corner
    • Building Modules
    • Share Ideas for WHMCS Modules
  • Community Competitions
    • Competitions
  • General Discussions
    • General Discussion
  • General Feedback & Assistance
    • WHMCS.Community Tips & Tricks
  • Third Party Developers's Topics
  • Turkish International Discussions's Topics
  • Russian International Discussions's Topics
  • Spanish International Discussions's Topics
  • Portuguese International Discussions's Topics
  • French International Discussions's Topics
  • Italian International Discussions's Topics
  • German International Discussions's Topics
  • WHMCS Brasil's Topics
  • WHMCS Brasil's Tópicos
  • ModulesGarden Club's Topics
  • Hungarian International Discussions's Segítség
  • ThemeMetro Club's Topics
  • WHMCS Services Club's Topics
  • SwiftModders Club's Topics
  • WHMCS Global Services Club's Topics
  • Zomex Club's Topics

WHMCS Version

  • V7.9.x Hotfixes
  • V7.8.x Hotfixes
  • V7.7.x Hotfixes

Find results in...

Find results that contain...

Date Created

  • Start


Last Updated

  • Start


Filter by number of...


  • Start



Found 3 results

  1. To activate the intelligent search to query results while typing instead of pressing the "Enter" key each time I have created simple ActionHook function that will integrate the code for both built-in template (v4 and Blend), the integration tested and is valid for WHMCS v6+ and v7+ 1) Create new PHP file inside /includes/hooks/ directory, you may use "IntelliSearchWhileTyping.php" as the file name or whatever you prefer. 2) Copy the following code inside it. 3) Done. <?php /** * Get Results From Intelligent Search While Typing * * Compatible with WHMCS v6+ and v7+ * Works with v4 and Blend templates * * @author SENTQ <development@sentq.com> * */ if (!defined("WHMCS")){ die("This file cannot be accessed directly"); } add_hook("AdminAreaHeadOutput", 1, function($vars){ # Template Blend if ($vars['template'] === "blend"){ return <<<EOF <script type="text/javascript"> /* Intelligent Search On Typing */ $(document).ready(function(){ $(document).on("input", "#intellisearchval", function(){ $("#intellisearchval").css("background-image","url('images/loading.gif')"); $.post("search.php", $("#frmintellisearch").serialize(), function(data){ $("#searchresultsscroller").html(data); $("#searchresults").slideDown("slow",function(){ $("#intellisearchval").css("background-image","url('images/icons/search.png')"); }); }); }); }); </script> EOF; } # Template v4 elseif ($vars['template'] === "v4"){ return <<<EOF <script type="text/javascript"> /* Intelligent Search On Typing */ $(document).ready(function(){ $(document).on("input", "#intellisearchval", function() { $.post("search.php", $("#frmintellisearch").serialize(), function(data){ if (data) { $("#searchresults").html(data); $("#btnIntelliSearch").hide(); $("#btnIntelliSearchCancel").removeClass('hidden').show(); $("#searchresults").hide().removeClass('hidden').slideDown(); } }); }); }); </script> EOF; } }); IntelliSearchWhileTyping.php
  2. Hello, I'm working on making it possible to show a Twitter feed based on the client. That way we can show different feeds for resellers and end-users. When someone isn't logged in I would probably show the end-user Twitter account. Changing the Twitter account for the URLs pointing to Twitter is easy. However with an AJAX (?) call it doesn't work. From WHMCS support I did hear I should be able to create some output on it when using the ClientAreaPage hookpoint. However this doesn't seem to work as the code below doesn't return any content (and that is what I would expect). <?php function whmcs_hook_test($vars){ var_dump($vars); } add_hook('ClientAreaPage',10,'whmcs_hook_test'); Any pointers as where to look? Or should I just create a new PHP file for it that gets the required information from Twitter and call that file using the Javascript?
  3. sebsimappus

    Stop scroll in cart

    Hello, I come to you to see if anyone is how the scroll Stope at some point. I joined the js code, in hope to have your help thank you in advance cordially $(document).ready(function () { var $orderSummaryEl = jQuery("#scroll"); if ($orderSummaryEl.length) { var offset = jQuery("#scrollingPanelContainer").parent('.row').offset(); //var maxTopOffset = jQuery("#scrollingPanelContainer").parent('.row').outerHeight() - 35; var maxTopOffset = jQuery("#scrollingPanelContainer").parent('.row'); var topPadding = 15; jQuery(window).resize(function() { offset = jQuery("#scrollingPanelContainer").parent('.row').offset(); //maxTopOffset = jQuery("#scrollingPanelContainer").parent('.row').outerHeight() - 35; maxTopOffset = jQuery("#scrollingPanelContainer").parent('.row'); repositionScrollingSidebar(); }); jQuery(window).scroll(function() { repositionScrollingSidebar(); }); repositionScrollingSidebar(); } function repositionScrollingSidebar() { if (jQuery("#scrollingPanelContainer").css('float') != 'left') { $orderSummaryEl.stop().css('margin-top', '0'); return false; } var heightOfOrderSummary = $orderSummaryEl.outerHeight(); var newTopOffset = jQuery(window).scrollTop() - offset.top + topPadding; if (newTopOffset > maxTopOffset - heightOfOrderSummary) { newTopOffset = maxTopOffset - heightOfOrderSummary; } if (jQuery(window).scrollTop() > offset.top) { $orderSummaryEl.stop().animate({ marginTop: newTopOffset }); } else { $orderSummaryEl.stop().animate({ marginTop: 0 }); } } });

Important Information

By using this site, you agree to our Terms of Use & Guidelines and understand your posts will initially be pre-moderated