Posts
 
Reputation
Joined
Last Seen
0 Reputation Points
Unknown Quality Score

No one has voted on any posts yet. Votes from other community members are used to determine a member's reputation amongst their peers.

0 Endorsements
~6K People Reached
Favorite Tags
Member Avatar for Navlag

I have this: $(document).ready(function() { $('input[type="button"]').click(function() { var sum = 0, count = 0, result; $('input[type="text"]').each(function() { var val = Number( $(this).val() ); if (val && val >= 0) { sum += Number(val); count++; } }); the error is that it does not take zero into account, for example, 10 …

Member Avatar for paulkd
0
215
Member Avatar for Navlag

So I have this OpenGL program that displays a cube using gluLookAt(0.0, 0.0, 5.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0); And it allows users to modify/rotate it along the x, y and z axis using input. Right now it looks it works pretty well, however, it terminates once the image …

Member Avatar for myk45
0
269
Member Avatar for Navlag

1. What happens when you add an element to a vector that is already at capacity? Does std::vector have a "capacity"? 2. In C++ and OOP in general, what do you call a design where a Person class inherits from Head, Arm, Body, Leg classes instead of the other way …

Member Avatar for Ancient Dragon
0
211
Member Avatar for Navlag

I tested and successfully used this SQL code below to input data into a database. INSERT INTO hraps (id, firstname, lastname, gender, year_of_1st_rappel, count_offset_proficiency, count_offset_operational, spotter) values(111111, 'World', 'Hello', 'Male', '2007', '1', '2', '0') Now I'm trying to integrate it into PHP like this: $query = "INSERT INTO hraps (firstname, …

Member Avatar for diafol
0
235
Member Avatar for Navlag

Hello. I received some code that has a section in which the variable $DB is established. $DB =& new DB($db_username, $db_password, $db_dsn, false); It does this by calling a function named DB, which is shown here below. /** * Constructor * * will set $DB->error and return false if login …

Member Avatar for veedeoo
0
211
Member Avatar for Navlag

Hello, I am just playing around with PHP and I have a silly little little login page, with the username and password hard coded in (not secure, I know). They are: username and password, respectively. Once logged in, there is a message saying I am logged in and a form …

Member Avatar for Navlag
0
303
Member Avatar for Navlag

Hello everyone, I have a PHP form that connects to an oracle DB and should send data to the database when the form is submitted, but I can't figure out why it's not loading any of the data into the database, everything seems to be correct (though this is my …

Member Avatar for LastMitch
0
2K
Member Avatar for Navlag

Hello, I am using the tutorial from Oracle's site on how to connect to a database in PHP using code similar to the one shown below. <?php // Create connection to Oracle $conn = oci_connect("phphol", "welcome", "//localhost/orcl"); $query = 'select * from departments'; $stid = oci_parse($conn, $query); $r = oci_execute($stid); …

Member Avatar for Navlag
0
126
Member Avatar for Navlag

The code below seems to work great in Google Chrome, it hides a question in a div unless the question before it is answered. However, it doesn't seem to work at all in I.E 8. Can someone give me a solution on how to make it work in both browswers …

Member Avatar for EvolutionFallen
0
329
Member Avatar for Navlag

Here is some code (snippet) from a function I have that takes a users "user_name" and "password" as parameters. There is an if else statement that triggers along the way, basically, if there is a value $v, then it look ups the users user_name and password in a table and …

Member Avatar for LastMitch
0
289
Member Avatar for Navlag

I'm new to PHP and was given a code snippet that looks like this: { $DB = new DB('xxxxxx','oooooo','gggggg'); $return_result = false; $this->clear_data(); $m = new xmlrpcmsg( 'ldapxml.authorize' , array( new xmlrpcval($user_name, "string") , new xmlrpcval($password, "string") ) ); // this is just a temp server for now $c = …

Member Avatar for Squidge
0
178
Member Avatar for Navlag

My code(below) displays only one "message" at a time and then prompts the user to delete the message in order to create a new one. How can I make it so that the user can constantly add new messages without having to delete the previous message? [CODE]import java.security.SecureRandom; import java.util.Iterator; …

Member Avatar for stultuske
0
249
Member Avatar for Navlag

Hi there. I have a few hundred/thousand macro enabled spreadsheets that need to be uploaded to a database. The spreadsheets have a button that copies the data over to the database and it prompts the user for a username and password in order to do so (same for all files). …

Member Avatar for toske
0
193
Member Avatar for Navlag

Writing a small program that requires me to convert strings to doubles and then back to strings. Right now, the code compiles but the answer is wrong, even though I am using an algorithm that I know is right in C++. Can someone tell me what I'm doing wrong? The …

Member Avatar for Navlag
0
114
Member Avatar for Navlag

Hello all, I am building a small file system in c++ that builds a table in a file called test.txt from information on another file. I am trying to copy the information over and then access a specific part of it based on the date. The data is copied over …

Member Avatar for Navlag
0
266
Member Avatar for Navlag

I am getting the following error: PII.cpp:266: error: 'struct std::string' has no member named 'getfirstblock' And I'm not sure how to fix it, since "int block" has to be equal to the firstblock of the file, how can I fix that error? Also, my "getfirstblock" function should return the block …

Member Avatar for baldwindc
0
884