Hi, I use the following code from phpmyadmin to reset one of my table's auto increment value from 1. SET @count = 0; UPDATE `mytable` SET `mytable`.`id` = @count:= @count + 1; ALTER TABLE `mytable` AUTO_INCREMENT = 1; But I want to run this query from PHP file and set a cron job everyday to do this. Table's storage engine type is INNODB. And id is not related in any of my tables (not a foreign key), so its ok to reset. Reason to reset is beacuse everyday million rows gets inserted and deleted once the day is completed. So …

Member Avatar
Member Avatar
+0 forum 3

I want to create an option that will reset my page once the user clicks on an alert the controller will reset to original form. I have the alert all set up but I am not sure how to do this. In JavaScript I created a function that did this `startANewGame();` which was this function startANewGame() { $('#startNew').click(function() { location.reload(true); $("input[type=submit]").val("Guess"); $("input[type=submit]").attr("id","guessButton"); }); // End of $('#startNew') } //End of function startANewGame() Is there a way to a function such as `reload` in AngularJS that will do this or do I need to create a function? Here is how my …

Member Avatar
+0 forum 0

I'm having an issue with coding a script that enables a logged in user to change his/her password. But when the form is submitted, a strange, blank page is displayed. There's no error message. Can you guys please, help me to resolve this issue? I'm not yet proficient in PHP and need all the insight I can get, to get my script to work fine. Here is the modifypass.php file: <?php // configuration require("../includes/config.php"); // if form was submitted if ($_SERVER["REQUEST_METHOD"] == "POST") { // validate submission if (empty($_POST["curpassword"])) { apologize("You must provide your current password."); } else if (empty($_POST["newpassword"])) …

Member Avatar
Member Avatar
+0 forum 11

Hello, I found this script and have used it for my login system. http://www.wikihow.com/Discussion:Create-a-Secure-Login-Script-in-PHP-and-MySQL I have changed some variables but none the less its the same. I am trying to create a reset password script here is what i tried so far: function resetPassword(){ //Main Info $id = $_POST['id']; $email = $_POST['email']; $pass= $_POST['password']; //salt and pass info $random_salt = hash('sha512', uniqid(mt_rand(1, mt_getrandmax()), true)); $password = hash('sha512', $pass.$random_salt); //Run the Query $update_stmt = $mysqli->prepare("UPDATE members SET password='$password' AND salt='$random_salt' WHERE id = ?"); $update_stmt->bind_param('s', $id); if($update_stmt->execute()) { if(login($email, $password, $mysqli) == true) { header('Location: ../signin.php?pass=1'); }else { header('Location: ../passreset.php?error=1'); } …

Member Avatar
Member Avatar
+0 forum 3

I'm trying to set up a timer that counts up to ten and starts/resets when the left mouse button is clicked (anywhere on the screen even when the application is in the background). I'm struggling to find a code that suggests it is possible and now I am starting to wonder even if it is possible in VB? Any help would be much appriciated. Thank you.

Member Avatar
Member Avatar
+0 forum 5

I have reset an Acer Laptop running Windows 8 to its original settings and it has brought up German. i need to know how to get it back to English. I DO NOT SPEAK GERMAAAANNNNN!!!!!!!

Member Avatar
Member Avatar
+0 forum 1

I need help writing a program in c++ where i have to write 3 different programs, a webcounter.cpp,webcounter.h, and test_prgm.cpp.So then i have to creat a makefile to compile them together, and the result of the program is "When I create the the counter, I would like to be able to set the value of the counter. Second, I need to be able to tell it "hit" and have it increment. Finally, I should be able to "reset" the counter, and "get" the current number of hits from it." it has to be a header file, and webcounter.cpp has my …

Member Avatar
Member Avatar
+0 forum 10

Hello everybody! I’m trying to create a program in which the user has the ability to move the image with mouse click and ability to zoom in and out by scrolling the mouse wheel. If the user wants to return to the original image size and position, it will be possible with a click of a button. I was able to do everything said above for the exception that after the user clicks on the reset button and zooms again, the previous size of the image is shown with the position where it was before the reset button was pressed. …

Member Avatar
Member Avatar
+0 forum 9

Hi Daniwebbers, I've created a web form and code in order to reset/clear the form with a button. However, in a specific circumstance, the form only resets properly if I go to a separate page then come back to the form and reset it. It only happens directly after I have passed a variable from another page to the form. I will try to lay this out. Here is the reset code from my form processing page: if(isset($_POST['reset'])) { session_start(); unset($_SESSION['cf_returndata'], $_SESSION['report']); header('location: ' . $_SERVER['HTTP_REFERER']); } The variable in question is "$_SESSION['report']." Here is the code from my form …

Member Avatar
Member Avatar
+0 forum 5

Using Visual Basic 10, and I am trying to identify min/max statistics and display the results. My calculations are working, but the display is not (line 68 & 80). With the way the code is written now, I don't get the error but my results are displayed as "The minimum monthly rainfall was *correct result* ("*g*"). "g" should be the month that corresponds to the minimum monthly rainfall. The same issue occurs on the maximum display. The line was initially written as *lblMinMonthly.Text = ("The minimum monthly rainfall was " & intMinRainfall.ToString() & "(" & strMonths(Me.intCount) & ")")* but received …

Member Avatar
Member Avatar
+0 forum 4

Hi, after searching a bit on the web I'm getting mixed messages about whether there's a difference between a hard and soft reset on a PC (shutting down vs. restarting). I know that shutting down removes power from all the cards and drives, but I'm specifically wondering about clearing memory. When you reboot without shutting down, does that clear the RAM and any other temporary storage fully or do you have to shut down to do so? Cheers

Member Avatar
Member Avatar
+0 forum 1

K! I have been off the daniweb for sometime now. But came back today. But i think i forgot my login details..... so i asked for the reset mail. And i got it, but when i click on the link, it just goes to my profile and no option whatsoever to reset the password or username. Please help me..... This is my new account, from the FB..... The link to my previous acc is http://www.daniweb.com/members/924687/Captain-Jake Please give a solution....... I need to reset my pass and userid.......

Member Avatar
Member Avatar
+0 forum 4

Hi everyone, I was writing a program to show visually some vectors I was implementing with Java but I ran into an issue. My program has 3 classes, a driver, a Vector class and a VectorDisplay. The driver and vector class are self explanatory, but here is the code. Driver: import phys.*; import java.util.*; public class Driver { public static Vector1 vect1 = new Vector1(50, 70); public static void dispVectStats() { vect1.dispVect(); vect1.drawVect(); } public static void main(String[] args) { System.out.print("\f"); dispVectStats(); } } Vector: package phys; import java.util.*; public class Vector1 { private int x; private int y; public …

Member Avatar
Member Avatar
+0 forum 3

Hello everyone In my app i'm using the counter and timer, But im stuck with resetting the counter My code is: If Timer2.Enabled = True Then counter = counter + 1 Label1.Text = counter If Label1.Text = "180" Then Timer2.Enabled = false Timer3.Enabled = true End If End If End Sub If Timer3.Enabled = true then counter = counter + 1 Label2.Text = counter If Label1.Text = "80" Then Timer3.Enabled = False end if But the problem is: When the second counter starts, It does continue on the first counter after it's stops which is 180, But what i was …

Member Avatar
Member Avatar
+0 forum 4

I have a friend laptop, which shortly recovered running without battery by cold treatment in freezer for two hours, but got symptoms back after trying to charge the battery overnight. Now it again tries to start, accesses the DVD drive and lights up some leads, but not by Power switch which does nothing, but by touch quick start panel push. I tried removing and reinserting memory chips and the hard disk. I noticed by trying to boot without memory inserted that booting behaviour did not change. When the laptop was running one evening, it overheated and switched off itself after …

Member Avatar
Member Avatar
+0 forum 4

1. Boot from Windows 7 Disk 2. Command Prompt – copy c:\windows\system32\sethc.exe c:\ copy c:\windows\system32\cmd.exe c:\windows\system32\sethc.exe 3. Activate Sticky keys by SHIFT 5 times In Command Prompt Enter: net user administrator **NewPassword**

Member Avatar
Member Avatar
+0 forum 2

please help

Member Avatar
Member Avatar
+0 forum 1

Hi I accidently double click on the toolbar and now ALL button on toolbar are gone. I want to reset it to default and get my buttons back. How to do that I tried to write click on Toolbar then Reset toobar , still no good I even tried reinstall lol but not working

Member Avatar
+0 forum 0

Hi, I am new to VB, and still learning. Please help me. I am developing a simple VB application, in Visual Studio 2010, where in we have to enter values in the fields given. I need to add a REFRESH button, which should act like a clr screen command. When i press that button, all the data fields should go back to its default values or the current values should be cleared. And I need to know how to connect this app to Outlook, so that it sends out a mail by fetching the data we entered in the fields.

Member Avatar
Member Avatar
+0 forum 4

I have created pages to comping some content and adding it into db. Here they are composing.php <html> <head> <title>Composing news</title> <script type="text/javascript" src="includes/jquery/jquery.min.js" ></script> <script type="text/javascript"> function reset_form() { document.getElementById("title").reset(); } </script> <script type="text/javascript"> $(document).ready(function(e) { // ready method make funtion available after the document has been loaded $("#submit").click(function(){ if($("#title").val().length == 0 || $("#category").val().length == 0 || $("#summary").val().length == 0 || $("#content").val().length == 0) { alert("Please fill into every blank!"); } // end if else { $.post("adding.php",{title: $("#title").val(), category: $("#category").val(), summary: $("#summary").val(),content: $("#content").val()}, function(data){ // post method is used to perform an AJAX HTTP POST request //alert("ok"); }); // …

Member Avatar
Member Avatar
+0 forum 1

Hello, I'm trying to make a very basic + - calculator in java using constructors after watching thenewboston video tutorial I tried to experiment with it. My litle project is almost finished my only problem is that the boolean I use is being reset after I assign it. If someone could take a look at I would really appriciate it. Also ignore the names of the class didn't bother to change it after the tutorial video. package bucky; public class tuna { private double num1; private double num2; private double awnser; public boolean plus; public tuna(double numbr1,double numbr2){ num1 = …

Member Avatar
Member Avatar
+0 forum 2

I want to re-use a vector<short> over and over in a performance critical loop. I only need the vector **size** to be reset to zero at the end of the loop. I'm worried that the myVector.clear() takes time to actually clear all the memory. Also, does the myVector.reserve() survive the clear()? vector<short> myVector; myVector.reserve(10000); while(true) { for(int i = 0; i < 10000; ++i) { myVector.push_back(*something++); } writeOut(myVector); myVector.clear(); }

Member Avatar
Member Avatar
+0 forum 3

I am not really good at HTML, (I assume this is HTML, at least, I do C++ mainly). I found this thing called "passwordreset.htm" and I got a little curious(this is on a school computer). I decided to open it, and I found something that looks like a password reset tool. I tried to reset my own, but it gave me error in line (I forget), continue to run script and Yes or No appeared. I opened in notepad and sent to my email to look at the source later. Here it is [CODE] <html> <head> <meta http-equiv="Content-Type" content="text/html; charset=windows-1252"> …

Member Avatar
Member Avatar
+0 forum 1

Hi everybody. I am new to Network programming, i need some help :) I have 4 "Intel Corporation 82574L Gigabit Network Connection" ethernet adapters on sandy bridge system. I'm using Linux kernel 2.6.35.10. While i'm passing traffic from iperf software on any of ethX port and disconnect ethernet cable of ethX port i get "e1000e 0000:02:00.0: ethX: Reset adapter" message on my terminal. Also, in the dmesg i found these errors.. ACPI Error (dsfield-0143): [CAPB] Namespace lookup failure, AE_ALREADY_EXISTS ACPI Error (psparse-0537): Method parse/execution failed [\_SB_.PCI0._OSC] (Node ffff88003f025710), AE_ALREADY_EXISTS ACPI: Marking method _OSC as Serialized because of AE_ALREADY_EXISTS error Please …

Member Avatar
Member Avatar
+0 forum 9

There was a paper jam in my hp P2055 laserjet printer. Of course, this is not a big news. However, after clearing it the printer is still complaining "jam in cartridge area" and gives advice how to fix the things, but the problem is, there is nothing extra visible any more inside the printer. How could I tell it to the printer, I mean, to make it start running again, which it refuses to do since we do not agree about the status of the things?

Member Avatar
Member Avatar
+0 forum 1

hi i seem to have run into a problem when adding records to a Typed file that already exists. I have used ReWrite method to create the file in the first place. [CODE] // Open the file for writing To AssignFile(F, ExtractFilePath(Application.ExeName) + 'bin\drivers' + (frm_vars.Driver1.Caption) + '\card.digi'); Rewrite(F); // Move To The End Of The File Seek(F, FileSize(F)); // Write a couple of records to the file Limits.tenhourdrive := ShortString(frm_vars.L10HrDriveAvailable1.Caption); Limits.fifteenhourshift := ShortString(frm_vars.L15HrShiftAvailable1.Caption); Write(F, Limits); // Close the file CloseFile(F);[/CODE] however if i check if the file exists, and then add records using Reset(F); it duplicates the first records …

Member Avatar
Member Avatar
+0 forum 3

I'm developing a web app in which I have a file upload option. The thing is, my file input is hidden, and instead, a textbox and a button are used, in order to style the input, copy the file input's value and allowing the user write a link address into the textbox (the php upload page recognizes the text in the textbox and takes action if the text is a hyperlink or a file upload). The problem is, when I submit the form, the php is catching the file input's value as empty. So I removed the hidden property of …

Member Avatar
Member Avatar
+0 forum 1

I am making a request form with a uniqe FORM NO. in order to recall the data faster. The FORM NO. is formated as follows, yyyyMMdd-000 the 000 will be incremented for every transaction made that's easy... but the problem is how to reset it back to 000 the following day? example: 20110713-000 (for the first transaction) 20110713-001 (for the second transaction) 20110713-002 (for the third transaction) . . (and so on) . 20110713-999 then the following day, the number should go back to 000 20110714-000 . . . 20110714-999 any suggestion? with out reseting it manually

Member Avatar
Member Avatar
+0 forum 6

Another issue with sha1. I am creating users via a registration form, that when submitted, has made the password a sha1. [B]Registration script:[/B] [CODE] if($_POST['pass1']==$_POST['pass2']){ $password = sha1(mysqli_real_escape_string($connection, $_POST['pass1'])); } [/CODE] When the user log in, I have this script using sha1. [B]Login script:[/B] [CODE] $password = sha1(mysqli_real_escape_string($connection, $_POST['password'])); $sql=("SELECT id, email, username FROM users WHERE email='$email' AND pass='$password' LIMIT 1"); // AND THEN THE USER CAN LOG IN, CAUSE THE ENTERED PASS IN THE LOGIN FORM CHANGES THE // PASS TO SHA1, LIKE WHEN THE USER REGISTERED. [/CODE] Then I have made a forgot password script, that creates a …

Member Avatar
Member Avatar
+0 forum 2

i was searching for a code to reset explorer! i found a code, but it isnt effective, is there a code to counter explorer weird behavior? another question, should i use apdiv , cause each time i use them (mainly by dreamweaver functionality), internet explorer goes mad!!!

Member Avatar
Member Avatar
+0 forum 1

The End.