Search Results

Search found 19 results on 1 pages for 'shinjuo'.

Page 1/1 | 1 

  • Centering Div in the middle of the page

    - by shinjuo
    What is the best way to center the entire page in the middle of the web browser? <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta content="text/html; charset=utf-8" http-equiv="Content-Type" /> <title>test.html</title> <style type="text/css"> .testimonials_png { position: absolute; left:20px; top:397px; width:220px; height:395px; background: url("test_files/testimonials.png") no-repeat; } .homeLink_png { position: absolute; left:-1px; top:243px; width:203px; height:75px; background: url("test_files/homeLink.png") no-repeat; } .sidingLink_png { position: absolute; left:202px; top:243px; width:180px; height:75px; background: url("test_files/sidingLink.png") no-repeat; } .windowsLink_png { position: absolute; left:382px; top:243px; width:181px; height:75px; background: url("test_files/windowsLink.png") no-repeat; } .roofingLink_png { position: absolute; left:563px; top:243px; width:183px; height:75px; background: url("test_files/roofingLink.png") no-repeat; } .aboutLink_png { position: absolute; left:746px; top:243px; width:205px; height:75px; background: url("test_files/aboutLink.png") no-repeat; } .banner_png { position: absolute; left:0px; top:0px; width:950px; height:243px; background: url("test_files/banner.png") no-repeat; } </style> </head> <body> <div class="testimonials_png"> </div> <div class="homeLink_png"> </div> <div class="sidingLink_png"> </div> <div class="windowsLink_png"> </div> <div class="roofingLink_png"> </div> <div class="aboutLink_png"> </div> <div class="banner_png"> </div> </body> </html>

    Read the article

  • 2D collision detection and stuff with OpenGL

    - by shinjuo
    I am working on a simple 2D openGL project. It contains a main actor you can control with the keyboard arrows. I got that to work okay. What I am wanting is something that can help explain how to make another actor object follow the main actor. Maybe a tutorial on openGL. The three main things I need to learn are the actor following, collision detection, and some kind of way to create gravity. Any good books or tutorials to help get me in the right direction would be great.

    Read the article

  • I have a php form dropdown menu that needs to send information

    - by shinjuo
    I have a dropdown menu that is filled by a mysql database. I need to select one and have it send the information for use on the next page after clicking submit. It does populate the drop down menu like it is supposed to it just does not seem to catch the data on the next page. Here is what I have: removeMain.php <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title></title> </head> <form action="remove.php" method="post"> <?php $link = mysql_connect('********', '********', '*********'); if (!$link){ die('Could not connect: ' . mysql_error()); } mysql_select_db("********", $link); $res = mysql_query("SELECT * FROM cardLists order by cardID") or die(mysql_error()); echo "<select name = CardID>"; while($row=mysql_fetch_assoc($res)) { echo "<option value=$row[ID]>$row[cardID]</a></option>"; } echo "</select>"; ?> Amount to Remove: <input type="text" name="Remove" /> <input type="submit" /> </form> <body> </body> </html> remove.php <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title></title> </head> <body> <?php $link = mysql_connect('*********', '*********', '*********'); if (!$link){ die('Could not connect: ' . mysql_error()); } mysql_select_db("***********y", $link); $query = sprintf("UPDATE cardLists SET AmountLeft = AmountLeft - %s WHERE cardID = '%s'", mysql_real_escape_string($_POST["Remove"]), mysql_real_escape_string($_POST["CardID"])); mysql_query($query); mysql_close($link); ?> <br /> <a href="removeMain.php"> <input type="submit" name="return" id="return" value="Update More" /></a> <a href="index.php"> <input type="submit" name="main" id="main" value="Return To Main" /></a> </body> </html>

    Read the article

  • Problem with PHP 'PHP_SELF'

    - by shinjuo
    I am having a bit of trouble. It does not seem to be a big deal, but I have created a page that the user can edit a MySQL database. Once they click submit it should process the php within the if statement and echo 1 record updated. The problem is that it does not wait to echo the statement. It just seems to ignore the way I wrote my if and display the whole page. Can anyone see where I went wrong. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title></title> </head> <body> <form action="<?php echo $_SERVER['PHP_SELF']; ?>" method="post"> <?php require("serverInfo.php"); ?> <?php $res = mysql_query("SELECT * FROM cardLists order by cardID") or die(mysql_error()); echo "<select name = 'Cards'>"; while($row=mysql_fetch_assoc($res)) { echo "<option value=\"$row[cardID]\">$row[cardID]</option>"; } echo "</select>"; ?> Amount to Add: <input type="text" name="Add" /> <input type="submit" /> </form> <?php if(isset($_POST['submit'])); { require("serverInfo.php"); mysql_query("UPDATE `cardLists` SET `AmountLeft` = `AmountLeft` + ".mysql_real_escape_string($_POST['Add'])." WHERE `cardID` = '".mysql_real_escape_string($_POST['Cards'])."'"); mysql_close($link); echo "1 record Updated"; } ?> <br /> <a href="index.php"> <input type="submit" name="main" id="main" value="Return To Main" /></a> </body> </html>

    Read the article

  • How to fill a drop down menu

    - by shinjuo
    I want to populate a drop down menu with a column from a MySQL database. I have the rest of my database set up, but at the moment it is just a text entry box and it would be easier just to select the actually entry from a list. Also does anyone know of a good tutorial or site that has tutorials and example codes for PHP and MySQL

    Read the article

  • Help understanding some OpenGL stuff

    - by shinjuo
    I am working with some code to create a triangle that moves with arrow keys. I want to create a second object that moves independently. This is where I am having trouble, I have created the second actor, but cannot get it to move. There is too much code to post it all so I will just post a little and see if anyone can help at all. ogl_test.cpp #include "platform.h" #include "srt/scheduler.h" #include "model.h" #include "controller.h" #include "model_module.h" #include "graphics_module.h" class blob : public actor { public: blob(float x, float y) : actor(math::vector2f(x, y)) { } void render() { transform(); glBegin(GL_TRIANGLES); glVertex3f(0.25f, 0.0f, -5.0f); glVertex3f(-.5f, 0.25f, -5.0f); glVertex3f(-.5f, -0.25f, -5.0f); glEnd(); end_transform(); } void update(controller& c, float dt) { if (c.left_key) { rho += pi / 9.0f * dt; c.left_key = false; } if (c.right_key) { rho -= pi / 9.0f * dt; c.right_key = false; } if (c.up_key) { v += .1f * dt; c.up_key = false; } if (c.down_key) { v -= .1f * dt; if (v < 0.0) { v = 0.0; } c.down_key = false; } actor::update(c, dt); } }; class enemyOne : public actor { public: enemyOne(float x, float y) : actor(math::vector2f(x, y)) { } void render() { transform(); glBegin(GL_TRIANGLES); glVertex3f(0.25f, 0.0f, -5.0f); glVertex3f(-.5f, 0.25f, -5.0f); glVertex3f(-.5f, -0.25f, -5.0f); glEnd(); end_transform(); } void update(controller& c, float dt) { if (c.left_key) { rho += pi / 9.0f * dt; c.left_key = false; } if (c.right_key) { rho -= pi / 9.0f * dt; c.right_key = false; } if (c.up_key) { v += .1f * dt; c.up_key = false; } if (c.down_key) { v -= .1f * dt; if (v < 0.0) { v = 0.0; } c.down_key = false; } actor::update(c, dt); } }; int APIENTRY WinMain( HINSTANCE hInstance, HINSTANCE hPrevInstance, char* lpCmdLine, int nCmdShow ) { model m; controller control(m); srt::scheduler scheduler(33); srt::frame* model_frame = new srt::frame(scheduler.timer(), 0, 1, 2); srt::frame* render_frame = new srt::frame(scheduler.timer(), 1, 1, 2); model_frame->add(new model_module(m, control)); render_frame->add(new graphics_module(m)); scheduler.add(model_frame); scheduler.add(render_frame); blob* prime = new blob(0.0f, 0.0f); m.add(prime); m.set_prime(prime); enemyOne* primeTwo = new enemyOne(2.0f, 0.0f); m.add(primeTwo); m.set_prime(primeTwo); scheduler.start(); control.start(); return 0; } model.h #include <vector> #include "vec.h" const double pi = 3.14159265358979323; class controller; using math::vector2f; class actor { public: vector2f P; float theta; float v; float rho; actor(const vector2f& init_location) : P(init_location), rho(0.0), v(0.0), theta(0.0) { } virtual void render() = 0; virtual void update(controller&, float dt) { float v1 = v; float theta1 = theta + rho * dt; vector2f P1 = P + v1 * vector2f(cos(theta1), sin(theta1)); if (P1.x < -4.5f || P1.x > 4.5f) { P1.x = -P1.x; } if (P1.y < -4.5f || P1.y > 4.5f) { P1.y = -P1.y; } v = v1; theta = theta1; P = P1; } protected: void transform() { glPushMatrix(); glTranslatef(P.x, P.y, 0.0f); glRotatef(theta * 180.0f / pi, 0.0f, 0.0f, 1.0f); //Rotate about the z-axis } void end_transform() { glPopMatrix(); } }; class model { private: typedef std::vector<actor*> actor_vector; actor_vector actors; public: actor* _prime; model() { } void add(actor* a) { actors.push_back(a); } void set_prime(actor* a) { _prime = a; } void update(controller& control, float dt) { for (actor_vector::iterator i = actors.begin(); i != actors.end(); ++i) { (*i)->update(control, dt); } } void render() { for (actor_vector::iterator i = actors.begin(); i != actors.end(); ++i) { (*i)->render(); } } };

    Read the article

  • Fancy box and youtube video problems

    - by shinjuo
    I have some fancy box photos and a youtube video, but when the fancy box picture opens the youtube video sits in front of it? Any ideas? Here is a snippet of my code: <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <script type="text/javascript"> <!-- var newwindow; function newWindow(url) { newwindow=window.open(url,'name','height=600,width=625'); if (window.focus) {newwindow.focus()} } // --> </script> <meta content="text/html; charset=utf-8" http-equiv="Content-Type" /> <title>onco Construction and Supply - Rhino Shield</title> <script type="text/javascript" src="http://code.jquery.com/jquery-1.4.2.min.js"></script> <script type="text/javascript" src="fancybox/jquery.mousewheel-3.0.2.pack.js"></script> <script type="text/javascript" src="fancybox/jquery.fancybox-1.3.1.js"></script> <link rel="stylesheet" type="text/css" href="fancybox/jquery.fancybox-1.3.1.css" media="screen" /> <link rel="stylesheet" type="text/css" href="../style3.css" media="screen" /> <script type="text/javascript"> $(document).ready(function() { $("a[rel=example_group]").fancybox({ 'transitionIn' : 'elastic', 'transitionOut' : 'elastic', 'titlePosition' : 'over', 'titleFormat' : function(title, currentArray, currentIndex, currentOpts) { return '<span id="fancybox-title-over">Image ' + (currentIndex + 1) + ' / ' + currentArray.length + (title.length ? ' &nbsp; ' + title : '') + '</span>'; } }); }); </script> <style type="text/css"> .commercial { position: absolute; left:205px; top:1175px; width:327px; height:auto; } .pictures { position: absolute; left: 50px; top: 1090px; width: 750px; height: auto; text-align: center; } </style> </head> <body> <div class="pictures"> <a rel="example_group" href="images/rhino/1.jpg"> <img src="images/rhino/small/1.jpg" alt=""/></a> <a rel="example_group" href="images/rhino/2.jpg"> <img src="images/rhino/small/2.jpg" alt=""/></a> <a rel="example_group" href="images/rhino/3.jpg"> <img src="images/rhino/small/3.jpg" alt=""/></a> <a rel="example_group" href="images/rhino/4.jpg"> <img src="images/rhino/small/4.jpg" alt=""/></a> <a rel="example_group" href="images/rhino/5.jpg"> <img src="images/rhino/small/5.jpg" alt=""/></a> <a rel="example_group" href="images/rhino/6.jpg"> <img src="images/rhino/small/6.jpg" alt=""/></a> </div> <div class="commercial"> <object width="445" height="364"><param name="movie" value="http://www.youtube.com/v/Mw3gLivJkg0&hl=en_US&fs=1&rel=0&color1=0x2b405b&color2=0x6b8ab6&border=1"></param> <param name="allowFullScreen" value="true"></param> <param name="allowscriptaccess" value="always"></param> <embed src="http://www.youtube.com/v/Mw3gLivJkg0&hl=en_US&fs=1&rel=0&color1=0x2b405b&color2=0x6b8ab6&border=1" type="application/x-shockwave-flash" allowscriptaccess="always" allowfullscreen="true" width="445" height="364"> </embed> </object> </div> </body> </html>

    Read the article

  • Problem with form buttons in IE

    - by shinjuo
    I have buttons on a page that look like: <a href="view.php"> <input type="button" name="view" value="View Database" /></a></p> IE does not support these buttons or multiple buttons I am not sure which one. Does anyone know how to fix this to work with IE?

    Read the article

  • Updating form values with javascript

    - by shinjuo
    I have a page that I made that is going to be used for retrieving shipping rates from UPS by entering the weight and zip. Everything works fine but what I want to add to it is the ability for the user to choose something on a form and have it update the value in a different form box. I think this is done with javascript. Any suggestions will help.

    Read the article

  • Trouble with a sequential search algorithm

    - by shinjuo
    I need to use this sequential search algorithm, but I am not really sure how. I need to use it with an array. Can someone point me in the correct direction or something on how to use this. bool seqSearch (int list[], int last, int target, int* locn){ int looker; looker = 0; while(looker < last && target != list[looker]){ looker++; } *locn = looker; return(target == list[looker]); }

    Read the article

  • Problems with MYSQL database

    - by shinjuo
    I have a database that worked fine until I decided to add a log onto the page. here is what I have now: <body> <?php if($_SERVER['REQUEST_METHOD'] == 'POST') { require("serverInfo.php"); mysql_query("UPDATE `cardLists` SET `AmountLeft` = `AmountLeft` + ".mysql_real_escape_string($_POST['Add'])." WHERE `cardID` = '".mysql_real_escape_string($_POST['Cards'])."'"); echo "\"" .$_POST['Add'] ."\" has been added to the inventory amount for the card \"". $_POST['Cards']. "\""; mysql_query("INSERT INTO `log` (`changes`, `amount`, `cardID`, `person`, Date)VALUES('ADDED','$_POST['Add']','$_POST['Cards']', '$_POST['Person']', NOW())"); mysql_close($link); } ?> <form action="<?php echo $_SERVER['PHP_SELF']; ?>" method="post"> <?php require("serverInfo.php"); ?> <?php $res = mysql_query("SELECT * FROM cardLists order by cardID") or die(mysql_error()); echo "<select name = 'Cards'>"; while($row=mysql_fetch_assoc($res)) { echo "<option value=\"$row[cardID]\">$row[cardID]</option>"; } echo "</select>"; ?> Amount to Add: <input type="text" name="Add" maxlength="8" /> Changes Made By: <select name="Person"> <option value="justin">Justin</option> <option value="chris">Chris</option> <option value="matt">Matt</option> <option value="dan">Dan</option> <option value="tim">Tim</option> <option value="amanda">Amanda</option> </select> <input type="submit" name ="submit" onClick= "return confirm( 'Are you sure you want to add this amount?');"> </form> <br /> <input type="button" name="main" value="Return To Main" onclick="window.location.href='index.php';" /> </body> </html> it works fine until I added the: mysql_query("INSERT INTO `log` (`changes`, `amount`, `cardID`, `person`, Date)VALUES('ADDED','$_POST['Add']','$_POST['Cards']', '$_POST['Person']', NOW())"); mysql_close($link); Can anyone see what is going on?

    Read the article

  • Sending Javascript variables.

    - by shinjuo
    I have a page that allows a user to choose some things in a form and it will calculate the weight using javascript. It breaks it up into 5 variables that I need to send to another page. Originally I was just having it put the variable into a text box and then I was posting that text box. However I dont want to have 5 text boxes. So now I need to somehow send or post the five variables to another page. Here is my javascript function. I need to post weightBoxOne - weightBoxFive js function function getWeight(){ var weightBoxOne; var weightBoxTwo; var totalWeight; var box = .5; var quantity = document.dhform.quantity.value; var cardSize = document.dhform.cardSize.value; if(cardSize == 0.0141){ if(quantity <= 1000){ weightBoxOne = (quantity * cardSize) + box; totalWeight = weightBoxOne; }else if(quantity > 1000 && quantity <= 2000){ weightBoxOne = (1000 * cardSize) + box; weightBoxTwo = ((quantity - 1000) * cardSize) + box; totalWeight = weightBoxOne + weightBoxTwo; }else if(quantity > 2000 && quantity <= 3000){ weightBoxOne = (1000 * cardSize) + box; weightBoxTwo = (1000 * cardSize) + box; weightBoxThree = ((quantity - 2000) * cardSize) + box; totalWeight = weightBoxOne + weightBoxTwo + weightBoxThree; }else if(quantity > 3000 && quantity <= 4000){ weightBoxOne = (1000 * cardSize) + box; weightBoxTwo = (1000 * cardSize) + box; weightBoxThree = (1000 * cardSize) + box; weightBoxFour = ((quantity - 3000) * cardSize) + box; totalWeight = weightBoxOne + weightBoxTwo + weightBoxThree + weightBoxFour; }else{ weightBoxOne = (1000 * cardSize) + box; weightBoxTwo = (1000 * cardSize) + box; weightBoxThree = (1000 * cardSize) + box; weightBoxFour = (1000 * cardSize) + box; weightBoxFive = ((quantity - 4000) * cardSize) + box; totalWeight = weightBoxOne + weightBoxTwo + weightBoxThree + weightBoxFour + weightBoxFive; } }else if(cardSize == 0.00949){ if(quantity <= 4000){ weightBoxOne = (quantity * cardSize) + box; totalWeight = weightBoxOne; }else{ weightBoxOne = (4000 * cardSize) + box; weightBoxTwo = ((quantity - 4000) * cardSize) + box; totalWeight = weightBoxOne + weightBoxTwo; } } document.rates.weight.value = totalWeight; } //--> this is the form that was originally posting <form action="getRates.php" name="rates" method="post" onSubmit="popupform(this, 'join')"> <table style="width: 216px"> <tr> <td style="width: 115px; height: 49px;"><span class="style16">Weight</span><br/> <input type="text" id="weight" name="weight" size="10" maxlength="4"/> </td> <td align="right" style="width: 68px; height: 49px;" valign="top"><span class="style16">Zip Code</span><br/> <input type="text" id="zip" name="zip" size="10" maxlength="5"/> </td> </tr> <tr> <td style="width: 115px"> <input name="submit" type="submit" value="Get Rate Costs" style="width: 138px" />

    Read the article

  • Adding with PHP to a MySQL database

    - by shinjuo
    I am pretty new to PHP and I am trying to make an inventory database. I have been trying to make it so that a user can enter a card ID and then amount the want to add to the inventory and have it update the inventory. For example someone could type in test and 2342 and it would update test. Here is what I have been trying with no success: add.html <body> <form action="add.php" method="post"> Card ID: <input type="text" name="CardID" /> Amount to Add: <input type="text" name="Add" /> <input type="submit" /> </form> </body> </html> add.php <?php $link = mysql_connect('tulsadir.ipowermysql.com', 'cbouwkamp', '!starman1'); if (!$link){ die('Could not connect: ' . mysql_error()); } mysql_select_db("tdm_inventory", $link); $add = $_POST[Add] mysql_query("UPDATE cardLists SET AmountLeft = '$add' WHERE cardID = 'Test'"); echo "test successful"; mysql_close($link); ?>

    Read the article

  • Vertically Align text in a Div

    - by shinjuo
    I am trying to find the most effective way to align text with a div. I have tried a few things and none seem to work. .testimonialText { position: absolute; left: 15px; top: 15px; width: 150px; height: 309px; vertical-align: middle; text-align: center; font-family: Georgia, "Times New Roman", Times, serif; font-style: italic; padding: 1em 0 1em 0; }

    Read the article

  • Counting number of searches

    - by shinjuo
    I am trying to figure out how to get the total number of tests each search makes in this algorithm. I am not sure how I can pass that information back from this algorithm though. I need to count how many times while runs and then pass that number back into an array to be added together and determine the average number of test. main.c #include <stdio.h> #include <stdlib.h> #include <time.h> #include <stdbool.h> #include "percentage.h" #include "sequentialSearch.h" #define searchAmount 100 int main(int argc, char *argv[]) { int numbers[100]; int searches[searchAmount]; int i; int where; int searchSuccess; int searchUnsuccess; int percent; srand(time(NULL)); for (i = 0; i < 100; i++){ numbers[i] = rand() % 200; } for (i = 0; i < searchAmount; i++){ searches[i] = rand() % 200; } searchUnsuccess = 0; searchSuccess = 0; for(i = 0; i < searchAmount; i++){ if(seqSearch(numbers, 100, searches[i], &where)){ searchSuccess++; }else{ searchUnsuccess++; } } percent = percentRate(searchSuccess, searchAmount); printf("Total number of searches: %d\n", searchAmount); printf("Total successful searches: %d\n", searchSuccess); printf("Success Rate: %d%%\n", percent); system("PAUSE"); return 0; } sequentialSearch.h bool seqSearch (int list[], int last, int target, int* locn){ int looker; looker = 0; while(looker < last && target != list[looker]){ looker++; } *locn = looker; return(target == list[looker]); }

    Read the article

  • Inaccessible item using C++ inheritance

    - by shinjuo
    I am working on C++ project that uses inheritance. I seem to have an error in visual studio in the below file administrator.h. It says that salariedemploye:salary on line 17 is inaccessible and I am not sure why. Admin.cpp #include namespace SavitchEmployees { Administrator::Administrator( ):SalariedEmployee(), salary(0) { //deliberately empty } Administrator::Administrator(const string& theName, const string& theSsn, double theAnnualSalary) :SalariedEmployee(theName, theSsn),salary(theAnnualSalary) { //deliberately empty } void Administrator::inputAdminData() { cout << " Enter the details of the administrator " << getName() << endl; cout << " Enter the admin title" << endl; getline(cin, adminTitle); cout << " Enter the area of responsibility " << endl; getline(cin, workingArea); cout << " Enter the immediate supervisor's name " << endl; getline(cin, supervisorName); } void Administrator::outputAdminData() { cout << "Name: " << getName() << endl; cout << "Title: " << adminTitle << endl; cout << "Area of responsibility: " << workingArea << endl; cout << "Immediate supervisor: " << supervisorName << endl; } void Administrator::printCheck() { setNetPay(salary); cout << "\n___________________________________\n" << "Pay to the order of " << getName() << endl << "The sum of" << getNetPay() << "Dollars\n" << "______________________________________\n" << "Check Stub Not negotiable \n" << "Employee Number: " << getSsn() << endl << "Salaried Employee(Administrator). Regular Pay: " << salary << endl << "______________________________________\n"; } } admin.h #include <iostream> #include "salariedemployee.h" using std::endl; using std::string; namespace SavitchEmployees { class Administrator : public SalariedEmployee { public: Administrator(); Administrator(const string& theName, const string& theSsn, double salary); double getSalary() const; void inputAdminData(); void outputAdminData(); void printCheck(); private: string adminTitle;//administrator's title string workingArea;//area of responsibility string supervisorName;//immediate supervisor }; } #endif SalariedEmployee.cpp namespace SavitchEmployees { SalariedEmployee::SalariedEmployee():Employee(),salary(0) { //deliberately empty } SalariedEmployee::SalariedEmployee(const string& theName, const string& theNumber, double theWeeklyPay) :Employee(theName, theNumber), salary(theWeeklyPay) { //deliberately empty } double SalariedEmployee::getSalary() const { return salary; } void SalariedEmployee::setSalary(double newSalary) { salary = newSalary; } void SalariedEmployee::printCheck() { setNetPay(salary); cout << "\n___________________________________\n" << "Pay to the order of " << getName() << endl << "The sum of" << getNetPay() << "Dollars\n" << "______________________________________\n" << "Check Stub NOT NEGOTIABLE \n" << "Employee Number: " << getSsn() << endl << "Salaried Employee. Regular Pay: " << salary << endl << "______________________________________\n"; } } Salariedemplyee.h #ifndef SALARIEDEMPLOYEE_H #define SALARIEDEMPLOYEE_H #include <string> #include "employee.h" namespace SavitchEmployees{ class SalariedEmployee : public Employee{ public: SalariedEmployee(); SalariedEmployee(const string& theName, const string& theSsn, double theWeeklySalary); double getSalary() const; void setSalary(double newSalary); void printCheck(); private: double salary; }; } #endif employee.cpp namespace SavitchEmployees { Employee::Employee():name("No name yet"),ssn("No number yet"),netPay(0){} Employee::Employee(const string& theName, const string& theSsn):name(theName),ssn(theSsn),netPay(0){} string Employee::getName() const { return name; } string Employee::getSsn() const { return ssn; } double Employee::getNetPay() const { return netPay; } void Employee::setName(const string& newName) { name = newName; } void Employee::setSsn(const string& newSsn) { ssn = newSsn; } void Employee::setNetPay(double newNetPay) { netPay = newNetPay; } void Employee::printCheck() const { cout << "\nERROR: pringCheck function called for an \n" << "Undifferentiated employee. Aborting the program!\n" << "Check with the author of this program about thos bug. \n"; exit(1); } }

    Read the article

  • News Aggregater of sorts

    - by shinjuo
    There is a website that my company uses that updates information about 3 specific things throughout the day. We use the information from 1 of them and what we are wanting to do is pull this information as it is added to their site and add it to a page of our own to view easier. Is this even possible? Can anyone point me in the direction of setting this up? It is all text that we want to pull.

    Read the article

1