How to create a button that redirect to certain location in a website which is still on the same page?

Member Avatar
Member Avatar
+0 forum 5

Hi I have problem that cannot show form validation errors in view . I am using ajax to post data to controller. Here is my Controller's Validation part private function _validate() { $this->form_validation->set_rules('Name', 'Name', 'required|alpha'); $this->form_validation->set_rules('CellNo', 'CellNo', 'required|numeric'); $this->form_validation->set_rules('Address', 'Address', 'required'); $this->form_validation->set_rules('Rate', 'Rate', 'required|numeric'); $this->form_validation->set_rules('Advance', 'Advance', 'required|numeric'); $this->form_validation->set_rules('BottlesQty', 'BottlesQty', 'required|numeric'); $this->form_validation->set_rules('DeliveryDay', 'DeliveryDay', 'required'); $this->form_validation->set_rules('DeliveryPerson', 'DeliveryPerson', 'required'); $this->form_validation->set_rules('referenceName', 'referenceName', 'required'); if ($this->form_validation->run() == FALSE) { $errors = validation_errors(); echo json_encode(['error'=>$errors]);} } Here is view with ajax <div id="print-error-msg" class="alert alert-danger " style="display:none"></div> //part of ajax posting to controller var formData = new FormData($('#form')[0]); $.ajax({ url : url, type: "POST", data: formData, …

Member Avatar
+0 forum 0

can i perform biometric process in php language if this is possible ,please give me some suggestion,.. if this is not possible then tell me how integrete c# or java biometric module in php

Member Avatar
Member Avatar
+0 forum 3

I have a yearly curriculum for my basketball workouts that I'd like to display online. I've created 53 unique workouts for each day of the week that include the main focus for the day, 6 drills, a quote, and a motivational story. I know I'd need a [datepicker](https://jqueryui.com/datepicker/) to accomplish this and the logic must employ both a [week number script](https://weeknumber.net/how-to/javascript) and a [getDay script](https://docs.microsoft.com/en-us/scripting/javascript/reference/getday-method-date-javascript), but I have absolutley no idea on how to get started from there. As the page loads, it should show today's workout. eg If it's the 17th Monday of the year, it would show that …

Member Avatar
Member Avatar
+0 forum 10

Greetings to everyone, I am working as a freelance web developer, i have more than 4 years experience in osclass scripts. I am working in the osclass scripts for the past 4 years and have created nearly 67 sites in osclass, and have created many plugins, cuztomized themes, plugin cuztomizations according to the clients need. I saw many of the post was unanswered here regarding the osclass scripts, so i make this new topic those who are wandering for a good programmer for their osclass script, reply me here if you need my support, thanks.

Member Avatar
+0 forum 0

i have been trying to upload image files in to my database but i failed in many ways, the form saves everything except the image files. i am not sure if its the php or the java or the html page, honestly i lost my path. i have included all my pages, any help would mean a lot, thanks!!! <html> <head> <meta charset="utf-8"> <title>PYB Register Bike</title> <link href="bootstrap-3.3.7/dist/css/bootstrap-theme.min.css" rel="stylesheet"> <!--styling css link --> <link href="bootstrap-3.3.7/dist/css/bootstrap.min.css" rel="stylesheet"> <!-- styling css link --> <link href="font-awesome-4.7.0/css/font-awesome.min.css" rel="stylesheet"> <!-- styling css link --> <link rel="stylesheet" href="../ProtectYourBike.css"> <!-- CSS Reference --> <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.7/jquery.js"></script> <script src="http://malsup.github.com/jquery.form.js"></script> …

Member Avatar
Member Avatar
+0 forum 1

I have this code that automatic calculate's the total quantity of the two textbox. The problem is it only works on the first row and first modal of the table when i try to click and enter values on the second row with the modal it doesnt work anymore. ![sample.png](/attachments/large/4/df4a066ffa07efde39e7e9df4be57db9.png "align-center") below is the code for calculation of quantity. (Im using the numeral.js for formatting and manipulating numbers.) <script> var a = 0; var b = 0; var c = 0; function calc(obj) { var d = obj.id.toString(); if (d == 'currentstock') { a = Number(obj.value); b = Number(document.getElementById('book_qty').value); } …

Member Avatar
Member Avatar
+0 forum 1

I have this code which I want to use but its color switching function doesn't work the way I want. Once I highlighted the target cells with one color, I also would like to highlight again with a different color without changing the color of the previously highlighted cells. Can somone help me with this, please? Here is a working example https://jsfiddle.net/a05nwahr/ I can only work with one color here only. Please ignore the messiness in the code, I hope you can see the problem in jquery. thanks. // JavaScript Document $(document).ready(function() { $('.selector').each(function() { $(this).on('click', check); }); $('.all').each(function() { …

Member Avatar
+0 forum 0

Hey everyone, I have a table, that is going to used to calculate IFTA, its a fueltax calculator populated by each state and the rate of each state. My question is, do i need to create a formula for each state? or can i do 1 formula and have it read for each class? Where it says [StateName] that is going to change to what state it is for. <table class="IFTAtable" id="FuelTaxIFTA" width="100%" border="1" cellpadding="2.5" cellspacing="5"> <tr> <th>Juristiction</th> <th>Rate Code</th> <th>Total IFTA Miles by State</th> <th>Taxable Miles</th> <th>MPG </th> <th>Taxable Gallons</th> <th>Tax Paid Gallons</th> <th>Net Taxable Gallons</th> <th>Tax Rate</th> <th>Tax …

Member Avatar
Member Avatar
+0 forum 10

Guys and gals, I am trying to do a simple LITTLE DIVIDE problem using jQuery its getting the values, but when its returning the results, it as if they are being divided by 10000, but I know its not... E.G. 50506/1000 = 50.506 in my jquery problem, it is coming up as E.G. 50506/1000 = 0.050506 Here is my jquery $(function(){ $('#copy').click(function(e){ var calculate = parseFloat($("#totalMiles").val()) / parseFloat($("#totalGallons").val()); $('#TotalMPG').val(calculate); var totalMPG = $('#TotalMPG').val(); $('.mpg').val(totalMPG); sync(); <--this is another function i have above this...disreguard }); }); can anyone see what my issue is?

Member Avatar
Member Avatar
+0 forum 1

Hi there, I am not sure where to post this question. I want to know how to animate objects like my "project images" when i click on menu item on web page. For better understanding please visit the following link and click on my work from top navigation. Thank you. http://it-worker.ondrejsvestka.cz/ For animation please click on links like Webdesign, SEO, Marketing, Other. I don't know where to start, I know jquery little bit but no idea how to implement this kind of animation.

Member Avatar
Member Avatar
+0 forum 1

Dear team, We are going to develop the WEB Application which contains more than 200 forms with different fields. Kindly, let us know which technology is best for front end (Angular 2 , React or any other technology)

Member Avatar
Member Avatar
+0 forum 4

Can u tell me how toset a reminder in a calendar and it should show out as a popup notification two hours before the event to occur.

Member Avatar
Member Avatar
+0 forum 1

Hello, I have a question, cek this code. It suppose to work like: http://www.soulfy.com/?a=add&pid=5 I move it to : http://www.soulfy.com/index.php It doesn't work just like the top link if you check the domain name. I have to add the following to code to the buttom codes to complete the code yet it turns out disappears the whole domain availability check instead of make it works. I suppose to add this code: function checkdomain() { var domainoption = jQuery(".domainoptions input:checked").val(); var sld = jQuery("#" + domainoption + "sld").val(); var tld = ''; if (domainoption == 'incart') var sld = jQuery("#" + …

Member Avatar
Member Avatar
+0 forum 1

Hi, i want to sort divs alphabetically both asc and desc. I am using a dropdown list created by using bootstrap: <div class="btn-group"> <a href="#" data-target="dropdown-menu" class="btn btn-default btn-block dropdown-toggle" data-toggle="dropdown"> Sort By <span class="caret"></span> </a> <ul class="dropdown-menu" style="width: 100%;"> <li><a href="#" class="nameAsc">Name: A to Z</a></li> <li><a href="#" class="nameDes">Name: Z to A</a></li> <li><a href="#" class="priceAsc">Price: Low to High</a></li> <li><a href="#" class="priceDes">Price: High to Low</a></li> </ul> </div> and my divs i want to sort are populated with data from database: <div class="gallery_product col-lg-4 col-md-4 col-sm-4 col-xs-6 filter"> <a href="products_details.php?pid=<?php echo $row['fld_product_id']; ?>" class="btn btn-warning btn-xs" role="button"><img src="products/<?php echo $row['fld_product_img'] ?>" class="img-responsive"></a> …

Member Avatar
Member Avatar
+0 forum 1

6 ‚óŹ4 I have a code that displays an array from GeoTab SDK, I am able to get the array to display in the console.log, and it populates the results like normal, However, When I try to populate the data in the table, nothing shows but the headings. Here is my code, and I will generate an object array and paste the code as well. I know the data that is generated is valid data, function generateDutyStatusLogSearch1(){ api.call("Get", { "typeName": "DutyStatusLog", "search": { "statuses": ["D", "OFF", "SB", "ON"], }, }, function(dutyStatusLogs) { var uniqueDrivers = {}; var multicall = []; …

Member Avatar
+0 forum 0

Hey everyone, this code below is giving me a weird error, Script 438: Object doesn't support property or method 'ajax'. I am testing this in Microsoft Edge, but...I have a website that uses this exact same code, and its working like normal. I am getting the `var id` to load properly, I am not sure why it is not working, since, its working on the other site. I copied and pasted the code to match exact. anywho, its stating that it at the `$.ajax({` line. <script> $(function(){ $('.get-msg').click(function(){ var id = $(this).attr('data-id'); $.ajax({ type : 'GET', url : 'viewmessage.php', data …

Member Avatar
Member Avatar
+0 forum 4

> this is php code for get value while ($row = $activeRiders->fetch(PDO::FETCH_ASSOC)){ $rider_name = $row['RiderName']; $longitude = $row['CurrentLongitude']; $latitude = $row['CurrentLatitude']; $locations[]=array( $rider_name, $latitude, $longitude ); } $markers = json_encode( $locations ); > Jquery function $(document).ready(function() { $('#map').height($('.page-container').height()); $( window ).resize(function() { $('#map').height($('.page-container').height()); }); <?php echo "var markers=$markers;\n"; ?> > Initialize Map map = new GMaps({ el: '#map', lat: 24.8615, lng: 67.0099, zoom: 12, zoomControl : true, zoomControlOpt: { style : 'SMALL', position: 'TOP_LEFT' }, circleOptions: { fillColor: '#ffff00', fillOpacity: 1, strokeWeight: 5, clickable: false, editable: true, zIndex: 1 }, panControl : false, streetViewControl : false, mapTypeControl: false, overviewMapControl: false, …

Member Avatar
+0 forum 0

I am literary about to bleed...I have a single controller that will accept POST request from an external domain. Once the post data arrives (usually a number or a date), it returns json data. The problem is CORS error in firefoz and chrome. Only that controller is going to be accessed from other domains. I have tried header('Access-Control-Allow-Origin: *'); header('Access-Control-Allow- Methods: POST, GET, PUT, DELETE, OPTIONS'); header('Access-Control-Allow-Headers: X-Requested-With, content-type, X-Token, x-token'); just after opening the php code, in the constructor and even the method but nothing changes at all. My current htaccess looks like this: RewriteEngine on RewriteCond $1 !^(index\.php|public|\.txt) …

Member Avatar
Member Avatar
+0 forum 2

Hey guys what do you think is the best website performance analysing tool available? Where can I get it? The site I'm looking to analyze : https://www.sellist.com

Member Avatar
Member Avatar
-1 forum 1

When click the map icon for loading the map, map show the error, Please solve the error

Member Avatar
Member Avatar
+0 forum 2

Hello, I wonder why I cannot hide pages with Jquery? home.blade.php <li> <input id="c10" type="checkbox"> <label for="c10"> <!-- <a href="#" @click.prevent="togglePage()"> --> <a href="{{ action('HomeController@getArticles') }}" id="hide"> @if($uri=="home/articles") <!-- <img src="{{url("")}}/images/button-10-hover.png"/> --> <div id="circle1"><div style="margin: -10px 0 0 0;"><img src="{{url("")}}/images/add/icons5-hover.png" width="30px" /></div></div> @else <!-- <img src="{{url("")}}/images/button-10.png"/> --> <div id="circle1"><div style="margin: -10px 0 0 0;"><img src="{{url("")}}/images/add/icons5.png" width="30px" /></div></div> @endif </a> </label> ... <script> $( "#hide" ).click(function() { $( "#container" ).hide( "slow", function() { alert( "Animation complete." ); }); }); </script> pages.blade.php @extends('home') @section('title', 'Home') @section('content') <section v-show="visiblePage" id="container"> <menu></menu> <cont> <center><b>{{ $pages2->pages_title }}</b></center><br> {!! $pages2->pages_content !!} </cont> <sidenav> <label for="c500" onclick="alert(1)">Label</label> …

Member Avatar
Member Avatar
+0 forum 5

hello, i'm having trouble with jquery navigator i don't think the problem is my code <script> $(document).ready(function(){ alert( "welcome"); alert("twice alert"); }); </script> in chrome i have this error: Uncaught SyntaxError: Unexpected token < in firefox i have this error : SyntaxError: expected expression, got '<' i looked on astackoverflow and many researches on google but couldn't find solution !

Member Avatar
Member Avatar
+0 forum 4

this code snippet works fine on its own but as soon as it's added to Magento it doesn't work. Anyone have any thoughts? <!-- Start Edits --> <script type="text/javascript" src="jquery.autocomplete.js"></script> <script type="text/javascript" > //<![CDATA[ var jQuery = jQuery.noConflict(); jQuery(document).ready(function() { jQuery("#antique_toys_materials").keyup(function() { var tag = jQuery(this).val(); if(tag != '') { jQuery.ajax( { type: "GET", url: "../../../../../../../../../../auto_suggest_original/autocomplete.php", data: "q=" + tag, cache: true, success: function(result) { jQuery("#antique_toys_materials").val(result); } } ); } return false; } ); } ); //]]> </script> Thanks!

Member Avatar
Member Avatar
+0 forum 1

//The php section of the code <?php function getJSONFromDB($sql){ $conn = mysqli_connect("localhost", "root", "","rent"); //echo $sql; $result = mysqli_query($conn, $sql)or die(mysqli_error()); $arr=array(); while($row = mysqli_fetch_assoc($result)) { $arr[]=$row; } return json_encode($arr); } $jsonData= getJSONFromDB("select Pic from Display"); $jsn=json_decode($jsonData); //for loop to retrieve rows from database for($i=0;$i<sizeof($jsn);$i++){ $a=$jsn[$i]->Pic; //here is the main problem echo "<html><body><img src='sponsor/$a.jpeg' alt=''></body></html>"; //here is the problem i am facing } ?> 01 //The php section of the code 02 <?php 03 function getJSONFromDB($sql){ 04 $conn = mysqli_connect("localhost", "root", "","rent"); 05 //echo $sql; 06 $result = mysqli_query($conn, $sql)or die(mysqli_error()); 07 $arr=array(); 08 while($row = mysqli_fetch_assoc($result)) { 09 $arr[]=$row; …

Member Avatar
Member Avatar
+0 forum 1

newbie here! I am working with a simple PHP form with few fields and few uploads. I want to use the Modal pop up form for this. Below codes are working fine. I was able to insert the fields into MYSQL successfully but I don't know how to add file upload of docs/images into a folder and insert the URL into MYSQL. Here are my codes: Calling the Modal Form -> <button class="btn btn-success btn-lg" data-toggle="modal" data-target="#modalForm"> Add </button> The MODAL FORM -> <div class="modal fade" id="modalForm" role="dialog"> <div class="modal-dialog"> <div class="modal-content"> <!-- Modal Header --> <div class="modal-header"> <button type="button" …

Member Avatar
Member Avatar
+0 forum 5

I use jQuery UI .droppable for dropping elements to divs. Now I need to prevent dropping to divs with class .box if they are not empty. if ($('.box').is(':empty')) { $(".box").droppable({ }); } But this makes all .box divs non-droppable whether they are empty or not.

Member Avatar
Member Avatar
+0 forum 2

hello danibe's friends i hope you all are doing well, i always had a question that i never asked so i would like my image to be full width not full screen just the width on any screen how can i do that without deforming the original image, have i to prepare it on photoshop with specific size or there is a solution with html/css or js ?? or jquerry ?

Member Avatar
Member Avatar
+0 forum 3

Hi, I understand the fundamental of replacing from a <div> to a <button>. i am having trouble though adding an id to the replacement. example> say i have the following code: <div class="container"> <div class="inner first">Hello</div> <div class="inner second">And</div> <div class="inner third">Goodbye</div> </div> I am applying this jquery to replace `<div class="inner first">Hello</div>` with `<button id="myBtn" class="btn">Hello</button>` <script> $( "div.first" ).replaceWith( "<button id="myBtn" class="btn">Hello</button>" ); </script> but it doesn't seem to work right. any help?

Member Avatar
Member Avatar
+0 forum 1

Hi all. Been fiddling with an idea about combining setters and getters in PHP. I really don't like magic methods (`__get` and `__set`) as they're not very flexible (IMO), but equally bore myself to distraction with set/get methods. Anyhow, having used jQuery for some time, I really liked the non-verbose methods of setting and getting in the client code: var p = myDiv.html(); //getting myDiv.html("Hi all"); //setting So I came up with this as an example: public function producers( $producers = null ) { if(func_num_args() > 0){ $this->_producers = $producers; return $this; }else{ return $this->_producers; } } It uses the …

Member Avatar
Member Avatar
+1 forum 7

The End.