<?xml version="1.0" encoding="utf-8" ?><?xml-stylesheet type="text/xsl" href="http://www.daniweb.com/js/rss.xsl"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/">
	<channel>
		<title>DaniWeb IT Discussion Community
								</title>
		<link>http://www.daniweb.com/</link>
		<description>Online discussion community for IT professionals and enthusiasts. Technology publication meets social media.</description>
		<language>en-US</language>
		<ttl>60</ttl>
		<!-- PubSubHubbub Discovery -->
		<link rel="hub" href="http://daniweb.superfeedr.com/" xmlns="http://www.w3.org/2005/Atom" />
		<link rel="self" href="http://www.daniweb.com/rss/pull" xmlns="http://www.w3.org/2005/Atom" />
		<!-- End Of PubSubHubbub Discovery -->
				<item>
			<title>C++ 3DProgramming, Collision Detection Problem against Model</title>
			<link>http://www.daniweb.com/software-development/cpp/threads/455150/c-3dprogramming-collision-detection-problem-against-model</link>
			<pubDate>Thu, 23 May 2013 07:35:01 +0000</pubDate>
			<description>Hi Im a student and just started 3D programming 2 weeks ago. I have this problem: I got a working collision detection against models created in Maya. But: The collision is only inside the model, with the normals on the model pointing out as it should be. If I revers ...</description>
			<content:encoded><![CDATA[ <p>Hi Im a student and just started 3D programming 2 weeks ago. I have this problem:</p>

<p>I got a working collision detection against models created in Maya. But:</p>

<p>The collision is only inside the model, with the normals on the model pointing out as it should be.<br />
If I revers the normals on the model(so you can se inside it but not inside out) the collision works great from the outside.<br />
I don't know if my Maya is configured wrong or if I did wrong, or is it my collision? Any idéa?</p>

<p>The collision is only intersecting the triangles inside for an example a box. Not from the outside...<br />
And I cant have reversed normals on models in the game, it dosent look well.</p>

<p>To mention the collision is against a world. WorldCollision.</p>

<p>Thanks</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/software-development/cpp/8">C++</category>
			<dc:creator>shadyreal</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/software-development/cpp/threads/455150/c-3dprogramming-collision-detection-problem-against-model</guid>
		</item>
				<item>
			<title>include() error :(</title>
			<link>http://www.daniweb.com/web-development/php/threads/455149/include-error-</link>
			<pubDate>Thu, 23 May 2013 07:21:30 +0000</pubDate>
			<description>when include file to dreamweaver i cant edit anything in design view. &lt;?php require('header.php');?&gt; What should i do?</description>
			<content:encoded><![CDATA[ <p>when include file to dreamweaver i cant edit anything in design view.<br />
&lt;?php require('header.php');?&gt;</p>

<p>What should i do?</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/web-development/php/17">PHP</category>
			<dc:creator>Shalomd</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/web-development/php/threads/455149/include-error-</guid>
		</item>
				<item>
			<title>Mysql IF Condition</title>
			<link>http://www.daniweb.com/web-development/databases/mysql/threads/455148/mysql-if-condition</link>
			<pubDate>Thu, 23 May 2013 06:22:42 +0000</pubDate>
			<description> CASE WHEN ((SELECT COUNT(id) FROM users) &gt; 0) THEN BEGIN INSERT INTO users(username,password) VALUES('Moshe','Ahuva'); END ELSE BEGIN INSERT INTO users(username,password) VALUES('Zvi','Idan'); END END My aim is to save with a condition. but it fails and says: &quot;Check the manual that correponds to the right syntax near ELSE BEGIN ....&quot;. please ...</description>
			<content:encoded><![CDATA[ <pre><code class="language-sql">CASE WHEN ((SELECT COUNT(id) FROM users) &gt; 0) THEN
    BEGIN
       INSERT INTO users(username,password) VALUES('Moshe','Ahuva');
   END
ELSE 
    BEGIN
       INSERT INTO users(username,password) VALUES('Zvi','Idan');
    END
END
</code></pre>

<p>My aim is to save with a condition. but it fails and says: "Check the manual that correponds to the right syntax near ELSE BEGIN ....". please re-write it better.</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/web-development/databases/mysql/126">MySQL</category>
			<dc:creator>mogaka</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/web-development/databases/mysql/threads/455148/mysql-if-condition</guid>
		</item>
				<item>
			<title>cron job to copy files from server to server</title>
			<link>http://www.daniweb.com/hardware-and-software/linux-and-unix/threads/455147/cron-job-to-copy-files-from-server-to-server</link>
			<pubDate>Thu, 23 May 2013 06:06:03 +0000</pubDate>
			<description>Hello guys, I need to create a daily backup for files and save them on another server I use rsync -av --progress --inplace --rsh='ssh -p22' /var/www/html/product root@37.101.11.144:/var/www/html/backup/ but this ask me for password , I want to create a cron job to copy files automatically at midnight. how can I ...</description>
			<content:encoded><![CDATA[ <p>Hello guys, I need to create a daily backup for files and save them on another server<br />
I use</p>

<pre><code>rsync -av --progress --inplace --rsh='ssh -p22' /var/www/html/product root@37.101.11.144:/var/www/html/backup/
</code></pre>

<p>but this ask me for password , I want to create a cron job to copy files automatically at midnight.<br />
how can I baypass the password ?</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/hardware-and-software/linux-and-unix/12">Linux and Unix</category>
			<dc:creator>OsaMasw</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/hardware-and-software/linux-and-unix/threads/455147/cron-job-to-copy-files-from-server-to-server</guid>
		</item>
				<item>
			<title>Indentation question</title>
			<link>http://www.daniweb.com/software-development/python/threads/455146/indentation-question</link>
			<pubDate>Thu, 23 May 2013 05:35:16 +0000</pubDate>
			<description>Hi * I'm trying to make a program that converts a vertical list to a horizontal one which works. But am trying to build in check for some correct user input an I get an Indentation error File &quot;.\dairymaster.py&quot;, line 19 pn_test = check_input('1', '2') ^ IndentationError: expected an indented ...</description>
			<content:encoded><![CDATA[ <p>Hi *<br />
I'm  trying to make a program that converts a vertical list to a horizontal one which works. But am trying to build in check for some correct user input an I get an Indentation error</p>

<p>File ".\dairymaster.py", line 19<br />
pn_test = check_input('1', '2')<br />
^<br />
IndentationError: expected an indented block</p>

<p>If I run this piece of code seperate it works fine but combination with the rest I get the above error</p>

<pre><code class="language-py">import sys

action = "draft"

#print ('Please enter which pen:')
#pn = raw_input()
def check_input(a, b):
    """
    check the input 
    """
    prompt = "Please enter which pen %s or %s: " % (a, b)
    while True:
        try:
            pn = str(raw_input(prompt))
            if pn == '1' or pn == '2':
                return pn
        except StringError:

pn_test = check_input('1', '2')
print(pn_test)

#print ('Please enter AM or PM:')
#moa = raw_input('Please enter AM or PM:')
def check_input(c, d):
    """
    check the input 
    """
    prompt = "Please enter either %s or %s: " % (c, d)
    while True:
        try:
            moa = str(raw_input(prompt))
            if moa == 'am' or moa == 'pm':
                return moa
        except StringError:

moa_test = check_input('am', 'pm')
print(moa_test)

#print ('Please enter how many days from now, enter = 0:')
#dfn = raw_input()
def check_input(e, f):
    """
    check the input 
    """
    prompt = "Please enter either %s or %s for today or tomorrow: " % (e, f)
    while True:
        try:
            dfn = str(raw_input(prompt))
            if dfn == '0' or dfn == '+1':
                return dfn
        except StringError:

dfn_test = check_input('0', '+1')
print(dfn_test)

print ('Please enter the filename:')
fname = raw_input()


handle = open(fname, "r")
list = handle.readlines()

combine = ''.join(list).replace("\n", " ")

if dfn == '0'
    return dfn == ' '

oname = "copyme.txt"
fout = open(oname, "w")
fout.write(action + pn + moa + ' ' + dfn + ' ')
fout.write(combine)
fout.close()
</code></pre>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/software-development/python/114">Python</category>
			<dc:creator>douwe1971</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/software-development/python/threads/455146/indentation-question</guid>
		</item>
				<item>
			<title>yahoo news </title>
			<link>http://www.daniweb.com/internet-marketing/social-media-and-communities/threads/455145/yahoo-news-</link>
			<pubDate>Thu, 23 May 2013 05:13:55 +0000</pubDate>
			<description>hello yahoo purchased tumblr in 1.1 billion</description>
			<content:encoded><![CDATA[ <p>hello yahoo purchased tumblr in 1.1 billion</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/internet-marketing/social-media-and-communities/50">Social Media and Communities</category>
			<dc:creator>spyindiarahul</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/internet-marketing/social-media-and-communities/threads/455145/yahoo-news-</guid>
		</item>
				<item>
			<title>scanf help</title>
			<link>http://www.daniweb.com/software-development/c/threads/455143/scanf-help</link>
			<pubDate>Thu, 23 May 2013 02:59:03 +0000</pubDate>
			<description>Hi, I am trying to write a program which read a certain input in a particular format and then gives an ouput. I wrote a code to read the file. Input is something like this. X 20 60 80 90 X 78 98 97 96 X 34 35 43 23 ...</description>
			<content:encoded><![CDATA[ <p>Hi,<br />
I am trying to write a program which read a certain input in a particular format and then gives an ouput. I wrote a code to read the file. Input is something like this.<br />
X 20 60 80 90<br />
X 78 98 97 96<br />
X 34 35 43 23<br />
Y 76 87 34<br />
Y 65 76 72<br />
Z 13 70 39<br />
So my reading function read the input and then it counts the number lines with X and Y. Now, when I wrote two different funcions to read X and Y lines. When I am finished reading the X lines, I go to read Y lines. The code skips the first Y line, because it has already read it without realising that it is a Y line, and then it read the next line while skipping the first Y line. Can I avoid that?</p>

<p>I use scanf to read the first character and then it is true I used scanf in a while loop to read the rest of the numbers and I store those numbers in an array.</p>

<p>As I know that it has already read the next character, can I test it if the character is Y? Because the input may not contain the Y line.</p>

<p>Thanks.</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/software-development/c/118">C</category>
			<dc:creator>sourabhyogi</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/software-development/c/threads/455143/scanf-help</guid>
		</item>
				<item>
			<title>Java Trident library issue</title>
			<link>http://www.daniweb.com/software-development/java/threads/455141/java-trident-library-issue</link>
			<pubDate>Thu, 23 May 2013 00:49:15 +0000</pubDate>
			<description>So, i have made a small test application attempting to learn and get used to the Trident library. I use a Timeline to alter the position of a JPanel. I was really impressed with how well it worked, until i added a background color to the moving panel, its all ...</description>
			<content:encoded><![CDATA[ <p>So, i have made a small test application attempting to learn and get used to the Trident library. I use a Timeline to alter the position of a JPanel. I was really impressed with how well it worked, until i added a background color to the moving panel, its all fun and games, until you use alpha!</p>

<p>Its such a strange issue, on the way up, the panel goes completely opaque, but then on the way back down, it gets its correct alpha value back and settles with that value.</p>

<p>the timeline code:</p>

<pre><code class="language-java">JPanel text = new JPanel();
text.setVisible(true);
text.setLocation(0, 150);
text.setSize(200, 150);
text.setBackground(new Color(0, 0, 0, 180));

final Timeline rolloverTimeline = new Timeline(text);
rolloverTimeline.addPropertyToInterpolate("location", new Point(0, 150), new Point(0, 50));
rolloverTimeline.setDuration(1000);

this.addMouseListener(new MouseAdapter() {
    @Override
    public void mouseEntered(MouseEvent e) {
        rolloverTimeline.play();
    }

    @Override
    public void mouseExited(MouseEvent e) {
        rolloverTimeline.playReverse();
    }
});

this.add(text);
</code></pre>

<p>Any help would be greatly appreciated, thanks</p>

<p>PS. i'd have posted it on the Trident forums, but that place is a ghost town</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/software-development/java/9">Java</category>
			<dc:creator>jasonw749</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/software-development/java/threads/455141/java-trident-library-issue</guid>
		</item>
				<item>
			<title>Algorithm for maximization</title>
			<link>http://www.daniweb.com/software-development/python/threads/455140/algorithm-for-maximization</link>
			<pubDate>Wed, 22 May 2013 23:24:14 +0000</pubDate>
			<description>Hello everyone, I have multiple lists of variables. Every list contains the variables corresponding to a single/unique entity. listVar_Entity1 = [x1, x2, x3, x4] listVar_Entity2 = [x5, x6, x7] listVar_Entity3 = [x8, x9, x10, x11, x12] # and so on Every member in a list has a mapping to each ...</description>
			<content:encoded><![CDATA[ <p>Hello everyone,<br />
I have multiple lists of variables. Every list contains the variables corresponding to a single/unique entity.</p>

<pre><code class="language-py">listVar_Entity1 = [x1, x2, x3, x4]
listVar_Entity2 = [x5, x6, x7]
listVar_Entity3 = [x8, x9, x10, x11, x12]
# and so on
</code></pre>

<p>Every member in a list has a mapping to each member of every other list for example:</p>

<pre><code class="language-py">mapping(x1,x9) = some_value
</code></pre>

<p>but there is no relation between variables within a list. I want to find the combination of members of different lists such that the addition of mapping between those variable is maximized assuming mapping(x1, x9) = mapping(x9, x1).<br />
Please help me writing this algorithm.<br />
Thanks<br />
sincerely,<br />
Himanshu</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/software-development/python/114">Python</category>
			<dc:creator>superbhimanshu</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/software-development/python/threads/455140/algorithm-for-maximization</guid>
		</item>
				<item>
			<title>Creating an autobalancer</title>
			<link>http://www.daniweb.com/software-development/java/threads/455139/creating-an-autobalancer</link>
			<pubDate>Wed, 22 May 2013 23:22:31 +0000</pubDate>
			<description>Hello! I've been busy passing exams, but now I'm free to code around again. So, in my usual style! **The goal:** I've been playing some Battlefield 3 during study breaks, and I've often been pissed off by BF3's autobalance mechanism. It's bad. Horrible. It makes me sad. I usually have ...</description>
			<content:encoded><![CDATA[ <p>Hello!<br />
I've been busy passing exams, but now I'm free to code around again.<br />
So, in my usual style!</p>

<p><strong>The goal:</strong><br />
I've been playing some Battlefield 3 during study breaks, and I've often been pissed off by BF3's autobalance mechanism. It's bad. Horrible. It makes me sad. I usually have to watch cat videos for an hour to recover from being autobalanced.<br />
But, it gave me the idea to code my own autobalancer! :D</p>

<p><strong>The problem:</strong><br />
To me, my logic seems fine, but the code breaks when I try to call the methods and objects in my main class.</p>

<p><strong>The code (Player.class):</strong></p>

<pre><code class="language-java">package autobalance;

import java.util.ArrayList;
import java.util.Iterator;
import java.util.List;
import java.util.Random;

public class Player {

    private Random R = new Random();
    private String name;
    private int team;
    private int score;
    List&lt;Player&gt; allPlayers;

    public Player() {
        this.name = "Soldier ";
        this.score = this.R.nextInt(10000);
        this.team = this.R.nextInt(2) + 1;
    }

    public Player addPlayer(String soldierName) {
        this.allPlayers = new ArrayList&lt;&gt;();
        Player P = new Player();
        P.setName(this.name + soldierName);
        allPlayers.add(P);
        return P;
    }

    public void showTeam(int T) {
        Iterator&lt;Player&gt; IT = this.allPlayers.iterator();
        while (IT.hasNext()) {
            Player temp = IT.next();
            if (temp.getTeam() == T) {
                System.out.println(temp.getName() + "-" + temp.getScore());
            }
        }
    }


    public void setName(String name) {
        this.name = name;
    }   

    public String getName() {
        return name;
    }

    public int getScore() {
        return score;
    }

    public int getTeam() {
        return team;
    }
}
</code></pre>

<p><strong>The code (main Autobalance.class):</strong></p>

<pre><code class="language-java">package autobalance;
public class Autobalance {
    public static void main(String[] args) {

        Player P = new Player();

        P.addPlayer("Mirza");
        P.addPlayer("Asmir");
        P.addPlayer("Ljubo");
        P.addPlayer("Slađo");
        P.addPlayer("Khan");
        P.addPlayer("Vpa");
        P.addPlayer("Marin");

    System.out.println("Team 1:");
        P.showTeam(1);
        System.out.println("Team 2:");
        P.showTeam(2);
    }
}
</code></pre>

<p><strong>Error report:</strong><br />
No red lines in the code, but when I run it, this happens:</p>

<pre><code class="language-java">Exception in thread "main" java.lang.RuntimeException: 
Uncompilable source code - constructor Player in class autobalance.
Player cannot be applied to given types;
  required: no arguments
  found: java.lang.String
  reason: actual and formal argument lists differ in length
    at autobalance.Autobalance.main(Autobalance.java:5)
Java Result: 1
BUILD SUCCESSFUL (total time: 0 s
</code></pre>

<p>It says line 5 in Autobalance.class is broken, does that mean all of Player.class is broken? :S<br />
I'd really appreaciate gurus' help. :)</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/software-development/java/9">Java</category>
			<dc:creator>Pobunjenik</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/software-development/java/threads/455139/creating-an-autobalancer</guid>
		</item>
				<item>
			<title>Accessing Data from Terminal and Making Available</title>
			<link>http://www.daniweb.com/software-development/cpp/threads/455138/accessing-data-from-terminal-and-making-available</link>
			<pubDate>Wed, 22 May 2013 21:10:30 +0000</pubDate>
			<description>Hello all, I'm both new to the forum, and to C++. The only languages I know (and not extremely well) are CLISP, ICARUS, and MatLab. I'm planning on learning C++, but I was wondering if this problem could be solved without a full-fledged understanding of C++ for the time being. ...</description>
			<content:encoded><![CDATA[ <p>Hello all, I'm both new to the forum, and to C++. The only languages I know (and not extremely well) are CLISP, ICARUS, and MatLab. I'm planning on learning C++, but I was wondering if this problem could be solved without a full-fledged understanding of C++ for the time being.</p>

<p>My current problem lies within access to data from a program that's already been written. This program is for a MAV Quadcopter and utilizes this code that can be found at the link here <a href="https://code.google.com/p/arducopter/downloads/list" rel="nofollow">https://code.google.com/p/arducopter/downloads/list</a></p>

<p>Arducopter 2.9.1b is the version we're working with as a team.</p>

<p>I'm trying to get the data to be accessed through the terminal, and thus able to utilize in real-time for other programs. I know the Arducopter program provides me with the data necessary as I can access it from programs like ArducopterMissionPlanner10 (Mission Planner 1.2.52 mav 1.0) and call it from test mode and setup modes within the terminal of that application.</p>

<p>Odds are I will get a C++ book here in the next couple of days or seek out an online route, so if you cannot help me initially, but have a good book to suggest or route to learn, I'd be appreciative in the same.</p>

<p>I appreciate any and all help in advance, and I'm looking forward to learning!</p>

<p>Best regards,</p>

<p>B</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/software-development/cpp/8">C++</category>
			<dc:creator>pbsarg</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/software-development/cpp/threads/455138/accessing-data-from-terminal-and-making-available</guid>
		</item>
				<item>
			<title>Undefined offset? Why?</title>
			<link>http://www.daniweb.com/web-development/php/threads/455136/undefined-offset-why</link>
			<pubDate>Wed, 22 May 2013 20:57:22 +0000</pubDate>
			<description>Why does this code snippet keep getting Undefined offset: 2, Undefined offset: 7, Undefined offset: 11, respectively? I'm not sure where I'm going wrong, for($i = 0; $i &lt; $user_length; $i++) // CHECKS IF THE USERNAME, FIRST NAME, IC NUMBER AND CONTACT NUMBER IS ALREADY BEEN REGISTERED AS A MEMBER ...</description>
			<content:encoded><![CDATA[ <p>Why does this code snippet keep getting Undefined offset: 2, Undefined offset: 7, Undefined offset: 11, respectively? I'm not sure where I'm going wrong,</p>

<pre><code>for($i = 0; $i &lt; $user_length; $i++) // CHECKS IF THE USERNAME, FIRST NAME, IC NUMBER AND CONTACT NUMBER IS ALREADY BEEN REGISTERED AS A MEMBER
                    {
                        $userdetail = explode(":", $user[$i]);
                        if ($_POST['ic'] == $userdetail[2])
                        {
                            echo "&lt;h2&gt;Sorry!&lt;/h2&gt;&lt;p&gt;The ic no is already in use!&lt;/p&gt;";
                            $error = 1;
                            $i = $user_length;
                        }
                        else if ($_POST['phone'] == $userdetail[7])
                        {
                            echo "&lt;h2&gt;Sorry!&lt;/h2&gt;&lt;p&gt;phone no is already in use!&lt;/p&gt;";
                            $error = 1;
                            $i = $user_length;
                        }
                        else if ($_POST['facename'] == $userdetail[10])
                        {   
                            echo "&lt;h2&gt;Sorry!&lt;/h2&gt;&lt;p&gt;The Username you provided is already in use!&lt;/p&gt;";
                            $error = 1;
                            $i = $user_length;
                        }

                    }
</code></pre>

<p>Here's the text file format the explode is reading from:</p>

<p>u0003:omied:123456-12-1234:male:married:privatesector:dfsfsdf:603-32323242:6016-2343432:omied@gmail.com:omeid123:dingo1234</p>

<p>as you can see, ic, phone, and facename are defined as 2, 7 and 10 following the format of the loop and array.</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/web-development/php/17">PHP</category>
			<dc:creator>xianamersu</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/web-development/php/threads/455136/undefined-offset-why</guid>
		</item>
				<item>
			<title>taking input from command line and outputting to a .txt file</title>
			<link>http://www.daniweb.com/software-development/cpp/threads/455134/taking-input-from-command-line-and-outputting-to-a-.txt-file</link>
			<pubDate>Wed, 22 May 2013 19:43:10 +0000</pubDate>
			<description>I have been getting used to c++ as I have been trying various scenarious on programs and exand on them with new concepts. This is my first try at exporting data from command line to a text file and the program runs fine with all the calculations. The real issue ...</description>
			<content:encoded><![CDATA[ <p>I have been getting used to c++ as I have been trying various scenarious on programs and exand on them with new concepts. This is my first try at exporting data from command line to a text file and the program runs fine with all the calculations. The real issue is that none of the outputs are exported to the text file. It is probably some simple oversight and want to say thanks in advance for helping me. Note- This program is supposed to take the inputs of a teacher and export the individual grade w/ letter the number of assignments and class average with letter to the text file.</p>

<pre><code class="language-cpp">#include &lt;iostream&gt;
#include &lt;cmath&gt;
#include &lt;cfloat&gt;
#include &lt;fstream&gt;

int i;
float testScore[100];
float sum = 0;
float clavg;
char grade;
int main()
{
    std::fstream myfile;
    myfile.open("grades.txt"); //name of file 
    std::cout&lt;&lt;"Please Enter Your Students Grades."&lt;&lt;std::endl;
    std::cout&lt;&lt;"Type 999 to get Avg"&lt;&lt;std::endl;
    for (i=0; i&lt;100; i++)
    {
        std::cin&gt;&gt;testScore[i];
        if(testScore[i] == 999)
        {
            break;
        }
            if (testScore[i] &gt;= 90 &amp;&amp; testScore[i]&lt;=100)
            {
                grade = 'A';

            }

            if (testScore[i] &gt;= 80 &amp;&amp; testScore[i]&lt;=89)
            {
                grade = 'B';

            }

            if (testScore[i] &gt;= 70 &amp;&amp; testScore[i]&lt;=79)
            {
                grade = 'C';

            }

            if (testScore[i] &gt;= 60 &amp;&amp; testScore[i]&lt;=69)
            {
                grade = 'D';

            }

            if (testScore[i] &gt;=0 &amp;&amp; testScore[i]&lt;=59)
            {
                grade = 'F';

            }

            sum+=testScore[i];
            myfile&lt;&lt;testScore[i]&lt;&lt;" "&lt;&lt;grade&lt;&lt;std::endl;
    }
    clavg = (sum/i);

    if (clavg &gt;= 90 &amp;&amp; clavg&lt;=100)
            {
                grade = 'A';

            }

            if (clavg&gt;= 80 &amp;&amp; clavg&lt;=89)
            {
                grade = 'B';

            }

            if (clavg &gt;= 70 &amp;&amp; clavg&lt;=79)
            {
                grade = 'C';

            }

            if (clavg&gt;= 60 &amp;&amp; clavg&lt;=69)
            {
                grade = 'D';

            }

            if (clavg &gt;=0 &amp;&amp; clavg&lt;=59)
            {
                grade = 'F';

            }
            myfile&lt;&lt;"Total Number of Assignments = "&lt;&lt;i&lt;&lt;std::endl;
            myfile&lt;&lt;"Find Grade = "&lt;&lt;clavg&lt;&lt;" "&lt;&lt;grade&lt;&lt;std::endl;

            myfile.close();

            system("pause");
}
</code></pre>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/software-development/cpp/8">C++</category>
			<dc:creator>gobiking</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/software-development/cpp/threads/455134/taking-input-from-command-line-and-outputting-to-a-.txt-file</guid>
		</item>
				<item>
			<title>foreach loop issues.</title>
			<link>http://www.daniweb.com/software-development/csharp/threads/455133/foreach-loop-issues</link>
			<pubDate>Wed, 22 May 2013 19:24:32 +0000</pubDate>
			<description>Ok the output of this code is Element[0] = 100 Element[0] = 101 Element[0] = 102 Element[0] = 103 Element[0] = 104 Element[0] = 105 Element[0] = 106 Element[0] = 107 Element[0] = 108 Element[9] = 109 its supposed to be Element[0] = 100 Element[1] = 101 Element[2] = 102 ...</description>
			<content:encoded><![CDATA[ <p>Ok the output of this code is<br />
Element[0] = 100<br />
Element[0] = 101<br />
Element[0] = 102<br />
Element[0] = 103<br />
Element[0] = 104<br />
Element[0] = 105<br />
Element[0] = 106<br />
Element[0] = 107<br />
Element[0] = 108<br />
Element[9] = 109</p>

<p>its supposed to be</p>

<p>Element[0] = 100<br />
Element[1] = 101<br />
Element[2] = 102<br />
Element[3] = 103<br />
Element[4] = 104<br />
Element[5] = 105<br />
Element[6] = 106<br />
Element[7] = 107<br />
Element[8] = 108<br />
Element[9] = 109</p>

<p>The code is below. I fixxed the issue, but this code snippet comes straight from a tutorial website.<br />
What I don't know is why doesn't the foreach()  loop add the Element numbers in? I had to change<br />
the  i = 0;   to  i = j - 100; in order to make it output properly. Is anyone else getting the zero's<br />
on their output? Again I am using Visual Studio Express 2012. Why doesn't their code snippet work? What's<br />
wrong with that foreach loop to cause i not to increment and display properly?</p>

<pre><code class="language-cs">foreach statement to iterate through an array.
using System;

namespace ArrayApplication
{
   class MyArray
   {
      static void Main(string[] args)
      {
         int []  n = new int[10]; /* n is an array of 10 integers */


         /* initialize elements of array n */         
         for ( int i = 0; i &lt; 10; i++ )
         {
            n[i] = i + 100;
         }

         /* output each array element's value */
         foreach (int j in n )
         {
            int i = 0;    //&lt;--- I changed this to int i = j - 100;  and the code works properly.
            Console.WriteLine("Element[{0}] = {1}", i, j);
            i++;
         }
         Console.ReadKey();
      }
   }
}
</code></pre>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/software-development/csharp/61">C#</category>
			<dc:creator>CodyOebel</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/software-development/csharp/threads/455133/foreach-loop-issues</guid>
		</item>
				<item>
			<title>Passing variable through URL</title>
			<link>http://www.daniweb.com/web-development/php/threads/455132/passing-variable-through-url</link>
			<pubDate>Wed, 22 May 2013 19:12:12 +0000</pubDate>
			<description>I want to pass a combo box value from url in php. I have no idea how to do it. I just try like this. This my combo box html code. &lt;select id=&quot;ID1&quot; name=&quot;place&quot; &gt; &lt;option value=&quot;Colombo&quot; selected=&quot;selected&quot;&gt;Colombo&lt;/option&gt; &lt;option value=&quot;Matara&quot;&gt;Matara&lt;/option&gt; &lt;option value=&quot;Galle&quot;&gt;Galle&lt;/option&gt; &lt;/select&gt; //What i want is pass selected value ...</description>
			<content:encoded><![CDATA[ <p>I want to pass a combo box value from url in php. I have no idea how to do it. I just try like this.<br />
This my combo box html code.</p>

<pre><code> &lt;select id="ID1" name="place" &gt;
&lt;option value="Colombo" selected="selected"&gt;Colombo&lt;/option&gt;
&lt;option value="Matara"&gt;Matara&lt;/option&gt;
&lt;option value="Galle"&gt;Galle&lt;/option&gt;
&lt;/select&gt;

//What i want is pass selected value through URL

   &lt;div style="float:right; padding-right:1px; padding-bottom:2px;"&gt; &lt;a href="MyCity.php?city1= &lt;?php echo $_GET["place"] ; ?&gt; &gt; Click here &lt;/a&gt;&lt;/div&gt;
</code></pre>

<p>I'm bit new to php and what is wrong with this code?<br />
im sure that 'MyCity.php' coding is correct, because i pass, hard coded value throgh above URL and could get that value from MyCity.php</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/web-development/php/17">PHP</category>
			<dc:creator>weeraa</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/web-development/php/threads/455132/passing-variable-through-url</guid>
		</item>
				<item>
			<title>Trying to learn Classes</title>
			<link>http://www.daniweb.com/software-development/python/threads/455131/trying-to-learn-classes</link>
			<pubDate>Wed, 22 May 2013 19:02:29 +0000</pubDate>
			<description>Hey guys, I'm trying to learn how to use classes and work with seperate files, and I been reading about it and now I tryed making a little short &quot;Hello World&quot; thingy but I don't really understand the self. things, I thought I did but it's not working so I ...</description>
			<content:encoded><![CDATA[ <p>Hey guys, I'm trying to learn how to use classes and work with seperate files, and I been reading about it and now I tryed making a little short "Hello World" thingy but I don't really understand the self. things, I thought I did but it's not working so I guess I diden't</p>

<p>Heres the code anyways:<br />
HelloWorld.py</p>

<pre><code class="language-py">class HelloWorld :

        def __init__(self):

            print("Hi")

        def Talk(self ,name):

            self.nameA = name
            print("Hello",self.nameA)
</code></pre>

<p>Main.py</p>

<pre><code class="language-py">import HelloWorld

HelloWorld.HelloWorld.Talk("Kevin")
</code></pre>

<p>I get the error:</p>

<pre><code class="language-py">Traceback (most recent call last):
  File "D:\PygameSpel\Test med klasser\Main.py", line 3, in &lt;module&gt;
    HelloWorld.HelloWorld.Talk("Kevin")
TypeError: Talk() takes exactly 2 arguments (1 given)
</code></pre>

<p>what am I missing?</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/software-development/python/114">Python</category>
			<dc:creator>Necrozze</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/software-development/python/threads/455131/trying-to-learn-classes</guid>
		</item>
				<item>
			<title>Copy specific rows from a cvs file to another cvs file</title>
			<link>http://www.daniweb.com/software-development/python/threads/455130/copy-specific-rows-from-a-cvs-file-to-another-cvs-file</link>
			<pubDate>Wed, 22 May 2013 18:17:33 +0000</pubDate>
			<description>I want to copy rows 3-5 to a new csv file. I can get the following code to copy the whole file to the new file but the only detail I have found about grabbing arbitrary rows consists of piecing array index numbers like in line 4 below. This may ...</description>
			<content:encoded><![CDATA[ <p>I want to copy rows 3-5 to a new csv file.<br />
I can get the following code to copy the whole file to the new file but the only detail I have found about grabbing arbitrary rows consists of piecing array index numbers like in line 4 below.  This may be helpful at some point, but right now I want the whole row, or a range of rows.<br />
I am pretty sure it is a simple thing, but apparently nobody else is writing about it.</p>

<pre><code class="language-py">    with open(filename, 'rb') as f:                         #This is scaffolding to see if the 
        reader = csv.reader(f)                              #read function worked  
        for row in reader:
            print("This is the header block", row[0], row[1])  
    with open('t_'+filename, 'wb') as title:                #This should be the start of the real code.
        writer = csv.writer(title)
        with open(filename, 'rb') as mycsv:
            reader = csv.reader(mycsv)
            for row in reader:
                writer.writerow(row)                        # I only want rows 3-5  
</code></pre>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/software-development/python/114">Python</category>
			<dc:creator>wolf29</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/software-development/python/threads/455130/copy-specific-rows-from-a-cvs-file-to-another-cvs-file</guid>
		</item>
				<item>
			<title>I don&#039;t know what I am doing....</title>
			<link>http://www.daniweb.com/software-development/vbnet/threads/455129/i-dont-know-what-i-am-doing</link>
			<pubDate>Wed, 22 May 2013 17:55:08 +0000</pubDate>
			<description>I am currently taking a programming class. I finished my work early one day and was bored so.. I decided to make a randomizer that will only pick a number a single time. I have been trying to make it, but I run into continous errors with it. It seems ...</description>
			<content:encoded><![CDATA[ <p>I am currently taking a programming class. I finished my work early one day and was bored so.. I decided to make a randomizer that will only pick a number a single time. I have been trying to make it, but I run into continous errors with it. It seems to work until the randomizer picks 1. I have no idea why this does not work, but if it does pick one several clicks later the program will crash. Also the program can start picking the other numbers multiple times. Eventually the option for one will go away, but only after several clicks of the button.<br />
 Button1 adds the numbers to a text file and button 2 picks the number. Button 3 is a reset.<br />
 This program was created to pick seats so I am using that as my variable.<br />
 Here is my code so far....</p>

<pre><code class="language-vb">Public Class Form1
    Public seat As Integer
    Dim r As Integer
    Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
        If My.Computer.FileSystem.FileExists("seats.txt") Then
            My.Computer.FileSystem.DeleteFile("seats.txt")
            For x = 1 To 5
                My.Computer.FileSystem.WriteAllText("seats.txt", Environment.NewLine + x.ToString, True)
            Next
            RemoveAtLine("seats.txt", 0)
        Else : For x = 1 To 5
                My.Computer.FileSystem.WriteAllText("seats.txt", Environment.NewLine + x.ToString, True)
            Next
            RemoveAtLine("seats.txt", 0)
        End If
    End Sub

    Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click
        r = IO.File.ReadAllLines("seats.txt").Length + 1
        Dim reader As New System.IO.StreamReader("seats.txt")
        Dim allLines As List(Of String) = New List(Of String)
        Do While Not reader.EndOfStream
            allLines.Add(reader.ReadLine())
        Loop
        reader.Close()
        If Val(TextBox1.Text) &lt;= r Then
            For x = 1 To Val(TextBox1.Text)
                Randomize()
                seat = Int(Rnd(1) * r)
                Label1.Text = Label1.Text + Environment.NewLine + ReadLine(seat, allLines)
                RemoveAtLine("seats.txt", seat - 1)
            Next x
        Else : MsgBox("Not enough seats left")
        End If
    End Sub

    Public Shared Sub RemoveAtLine(ByVal filePath As String, Optional ByVal lineRemove As Integer = -1)
        If (String.IsNullOrEmpty("seats.txt")) Then
            Return
        End If
        Dim lines As New List(Of String)(IO.File.ReadAllLines("seats.txt"))
        If (lineRemove &gt;= 0 And lineRemove &lt;= lines.Count) Then
            lines.RemoveAt(lineRemove)
        End If
        IO.File.WriteAllLines("seats.txt", lines.ToArray())
    End Sub

    Public Function ReadLine(ByVal lineNumber As Integer, ByVal lines As List(Of String)) As String
        If lineNumber = 0 Then
            Return lines(lineNumber)
        Else
            Return lines(lineNumber - 1)
        End If
    End Function

    Private Sub Button3_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button3.Click
        If My.Computer.FileSystem.FileExists("seats.txt") Then My.Computer.FileSystem.DeleteFile("seats.txt")
    End Sub
End Class
</code></pre>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/software-development/vbnet/58">VB.NET</category>
			<dc:creator>schroaus</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/software-development/vbnet/threads/455129/i-dont-know-what-i-am-doing</guid>
		</item>
				<item>
			<title>Trying to input 3 books into a struct. Need help !</title>
			<link>http://www.daniweb.com/software-development/csharp/threads/455128/trying-to-input-3-books-into-a-struct.-need-help-</link>
			<pubDate>Wed, 22 May 2013 17:40:54 +0000</pubDate>
			<description>I am currently following tutorials on c# as I am a c++ programmer, and am wanting to see what all the .NET talk is about with c# ;). Here is what I want my program to do. It asks the user to input title, author, subject, and bookID for 3 ...</description>
			<content:encoded><![CDATA[ <p>I am currently following tutorials on c# as I am a c++ programmer, and am wanting to see what all the .NET talk is about with c#  ;). Here is what I want my program to do.  It asks the user to input  title, author, subject, and bookID  for  3 books (or however many I set the loop for).<br />
I am a bit confused with the usage of  the foreach loop. Can someone lend me a hand here please ?</p>

<p>Thank you!</p>

<pre><code class="language-cs">using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace ConsoleApplication1
{


    class StringProg
   {
        struct book
        {
            public string title;
            public string author;
            public string subject;
            public int bookID;

            public void Getinfo()
            {
                Console.WriteLine("Please enter the title of the book:");
                title = Console.ReadLine();
                Console.WriteLine("Please enter the author of the book:");
                author = Console.ReadLine();
                Console.WriteLine("Please enter the subject of the book:");
                subject = Console.ReadLine();
                Console.WriteLine("Please enter the book ID of the book:");
                bookID = Convert.ToInt32(Console.ReadLine());

            }

            public void Display()
            {

                Console.Clear();
                Console.WriteLine("This is the information for the book you entered:\n\n");
                Console.WriteLine(title);
                Console.WriteLine(author);
                Console.WriteLine(subject);
                Console.WriteLine(bookID);
            }
        }

      static void Main(string[] args)
      {

          book[] books = new book[3];
          for (int i = 0; i &lt; 3; i++)
          {
              Console.WriteLine("Getting book information for book #:{0}\n\n", i);

          foreach(int j in books[i])
          {
              books[j].Getinfo();
              books[j].Display();
          }
          }
          Console.ReadLine();
      }

   }
}
</code></pre>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/software-development/csharp/61">C#</category>
			<dc:creator>CodyOebel</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/software-development/csharp/threads/455128/trying-to-input-3-books-into-a-struct.-need-help-</guid>
		</item>
				<item>
			<title>hard drive docking station usage with 3.5&#039;&#039; Hard Drive</title>
			<link>http://www.daniweb.com/hardware-and-software/pc-hardware/storage/threads/455127/hard-drive-docking-station-usage-with-3.5-hard-drive</link>
			<pubDate>Wed, 22 May 2013 17:27:00 +0000</pubDate>
			<description>Chaps, just bought a Hard drive docking station for my 3.5&quot; Hard Drive. This can be used for all sort of things, 3.5, 2.5, SD, USB etc etc, you can see it in the first picture ![6d7dc6ccb7cbf1014d447a842a474237](/attachments/fetch/L2ltYWdlcy9hdHRhY2htZW50cy8yLzZkN2RjNmNjYjdjYmYxMDE0ZDQ0N2E4NDJhNDc0MjM3LmpwZw%3D%3D/500 &quot;6d7dc6ccb7cbf1014d447a842a474237&quot;) At the bottom there is a button that has allegedly something to ...</description>
			<content:encoded><![CDATA[ <p>Chaps, just bought a Hard drive docking station for my 3.5" Hard Drive.<br />
This can be used for all sort of things, 3.5, 2.5, SD, USB etc etc, you can see it in the first picture <img src="/attachments/fetch/L2ltYWdlcy9hdHRhY2htZW50cy8yLzZkN2RjNmNjYjdjYmYxMDE0ZDQ0N2E4NDJhNDc0MjM3LmpwZw%3D%3D/500" alt="6d7dc6ccb7cbf1014d447a842a474237" title="6d7dc6ccb7cbf1014d447a842a474237" /></p>

<p>At the bottom there is a button that has allegedly something to do with what sort of HD you use: one position if for 3.5' and one is for 2.5'. I had a look on the instruction, on youtube and some guides I have managed to download from the net but none of them mentions this at all. I left the switch as it is in the picture<br /><img src="/attachments/fetch/L2ltYWdlcy9hdHRhY2htZW50cy8yLzZjMDM0NjFhM2E5YzZjMzJiNTg2MmIwNGZhYTZkZmFkLmpwZw%3D%3D/500" alt="6c03461a3a9c6c32b5862b04faa6dfad" title="6c03461a3a9c6c32b5862b04faa6dfad" /></p>

<p>and I plugged my 3.5'HD. It worked and the data seem to be opening ok, so hopefully I haven't fried anything but I wonder how true this thing with the switch it. If you wonder where I icked that up, it was from the picture that is on ebay, you can see it here if you scroll down <a href="http://www.ebay.co.uk/itm/200859352737?ssPageName=STRK:MEWNX:IT&amp;_trksid=p3984.m1497.l2649" rel="nofollow">http://www.ebay.co.uk/itm/200859352737?ssPageName=STRK:MEWNX:IT&amp;_trksid=p3984.m1497.l2649</a><br />
Has it got anything to do with the power supply or something? Any idea as to what I should do?<br />
thanks</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/hardware-and-software/pc-hardware/storage/105">Storage</category>
			<dc:creator>Violet_82</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/hardware-and-software/pc-hardware/storage/threads/455127/hard-drive-docking-station-usage-with-3.5-hard-drive</guid>
		</item>
				<item>
			<title>How are Android devices rooted?</title>
			<link>http://www.daniweb.com/hardware-and-software/tablets-and-mobile-devices/threads/455126/how-are-android-devices-rooted</link>
			<pubDate>Wed, 22 May 2013 17:00:17 +0000</pubDate>
			<description>Hello, I am curious about how to root an Android phone without using any one click methods. A Google search returns only how to use programs to do this for you. Obviously there is a security vulnerability that is exploited, but I'd like to know in detail how this is ...</description>
			<content:encoded><![CDATA[ <p>Hello,</p>

<p>I am curious about how to root an Android phone without using any one click methods. A Google search returns only how to use programs to do this for you. Obviously there is a security vulnerability that is exploited, but I'd like to know in detail how this is done.</p>

<p>Thanks,<br />
Cheeve</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/hardware-and-software/tablets-and-mobile-devices/98">Tablets and Mobile Devices</category>
			<dc:creator>Cheeve</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/hardware-and-software/tablets-and-mobile-devices/threads/455126/how-are-android-devices-rooted</guid>
		</item>
				<item>
			<title>Windоws Fоrms tеxt аlignment С++</title>
			<link>http://www.daniweb.com/software-development/cpp/threads/455125/windws-frms-txt-lignment-</link>
			<pubDate>Wed, 22 May 2013 16:56:11 +0000</pubDate>
			<description>help me to write a program which sets/arrаnges spacеs in width, аlign left, аlign right how can I align text? pls,can you explain in detail?</description>
			<content:encoded><![CDATA[ <p>help me to write a program which sets/arrаnges spacеs in width, аlign left, аlign right<br />
how can I align text?<br />
pls,can you explain in detail?</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/software-development/cpp/8">C++</category>
			<dc:creator>dualstar</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/software-development/cpp/threads/455125/windws-frms-txt-lignment-</guid>
		</item>
				<item>
			<title>.js validation works for email but not submission to database.</title>
			<link>http://www.daniweb.com/web-development/javascript-dhtml-ajax/threads/455124/.js-validation-works-for-email-but-not-submission-to-database</link>
			<pubDate>Wed, 22 May 2013 16:42:00 +0000</pubDate>
			<description>Hi: i have site contact form that validates required fields w/ .js And php. if browser has javascript turned on, the req'd info error message will show next to the field boxes .. if javascript is turned off, then user will see the same thing but coming from php instead... ...</description>
			<content:encoded><![CDATA[ <p>Hi:</p>

<p>i have site contact form that validates required fields w/ .js And php.<br />
if browser has javascript turned on, the req'd info error message will show next to the field boxes ..</p>

<p>if javascript is turned off, then<br />
user will see the same thing but coming from php instead...</p>

<p>the submit goes to database and personal email.<br />
email received shows complete field boxes info.. as expected..</p>

<p>the database will show incomplete submissions that the .js was sposed to stop..<br />
example:: like name is filled but missing email and such..</p>

<p>how can this be so?...<br />
must be something simple//</p>

<p>i didnt try to disable the .js validation to see what happens..<br />
i would rather fix it and keep it</p>

<p>here is code if someone can look at it..<br />
<a href="http://jsbin.com/ixupuk/1/edit" rel="nofollow">http://jsbin.com/ixupuk/1/edit</a></p>

<p>thanx</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/web-development/javascript-dhtml-ajax/117">JavaScript / DHTML / AJAX</category>
			<dc:creator>amkaos</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/web-development/javascript-dhtml-ajax/threads/455124/.js-validation-works-for-email-but-not-submission-to-database</guid>
		</item>
				<item>
			<title>OnPropertyChange</title>
			<link>http://www.daniweb.com/web-development/javascript-dhtml-ajax/threads/455123/onpropertychange</link>
			<pubDate>Wed, 22 May 2013 16:36:37 +0000</pubDate>
			<description>For a script that needs to be run on multiple pages with different coding etiquettes, I need to be able to figure out when there is some dynamic change occuring in the DOM. MutationObservers cater for Chrome and Firefox but I'm having problems with IE so onpropertychange event is something ...</description>
			<content:encoded><![CDATA[ <p>For a script that needs to be run on multiple pages with different coding etiquettes, I need to be able to figure out when there is some dynamic change occuring in the DOM. MutationObservers cater for Chrome and Firefox but I'm having problems with IE so onpropertychange event is something I've chosen to use as it appears to be the only thing that MAY give the behaviour I want.</p>

<pre><code class="language-js">document.attachEvent("onpropertychange", doThis);
</code></pre>

<p>The above is the function which fires the doThis method whenever something occurs. But some of the pages my script needs to run on have unlimited scrolls (similar to what Facebook, LinkedIn have) and rescanning the entire page each time the event fires in order to detect that element where a property was changed is very resource intensive.</p>

<p>If only there was some way to get the particular element that caused the propertychange I would be so happy..</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/web-development/javascript-dhtml-ajax/117">JavaScript / DHTML / AJAX</category>
			<dc:creator>asif49</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/web-development/javascript-dhtml-ajax/threads/455123/onpropertychange</guid>
		</item>
				<item>
			<title>Progress Bar using JavaScript</title>
			<link>http://www.daniweb.com/web-development/javascript-dhtml-ajax/threads/455122/progress-bar-using-javascript</link>
			<pubDate>Wed, 22 May 2013 16:29:42 +0000</pubDate>
			<description>Can anyone pls help me with how to create a Progress Bar by using JavaScript methods like setInterval() ?</description>
			<content:encoded><![CDATA[ <p>Can anyone pls help me with how to create a Progress Bar by using JavaScript methods like setInterval() ?</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/web-development/javascript-dhtml-ajax/117">JavaScript / DHTML / AJAX</category>
			<dc:creator>Bibek_NS</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/web-development/javascript-dhtml-ajax/threads/455122/progress-bar-using-javascript</guid>
		</item>
				<item>
			<title>How to call 2 tables with matching fields</title>
			<link>http://www.daniweb.com/web-development/php/threads/455121/how-to-call-2-tables-with-matching-fields</link>
			<pubDate>Wed, 22 May 2013 15:52:00 +0000</pubDate>
			<description>I have a MySQL DB with 2 Tables in particular, &quot;Properties&quot; and &quot;Tenants&quot;. Each Table has a unique address Field &quot;propAddress&quot; &amp; &quot;TenAddress&quot;. I have a PHP page with a repeating reigon that lists all properties in the DB. What I'm trying to do is list all the tenants info ...</description>
			<content:encoded><![CDATA[ <p>I have a MySQL DB with 2 Tables in particular, "Properties" and "Tenants". Each Table has a unique address Field "propAddress" &amp; "TenAddress".<br />
I have a PHP page with a repeating reigon that lists all properties in the DB.<br />
What I'm trying to do is list all the tenants info to the matching property based on the addresses.<br />
I have it in my mind I should be using the "Where Clause".<br />
Any advise will be greatly appreciated.</p>

<pre><code>mysql_select_db($database_rent, $rent);
$query_RsProp = "SELECT * FROM Properties ORDER BY PropId ASC";
$query_limit_RsProp = sprintf("%s LIMIT %d, %d", $query_RsProp, $startRow_RsProp, $maxRows_RsProp);
$RsProp = mysql_query($query_limit_RsProp, $rent) or die(mysql_error());
$row_RsProp = mysql_fetch_assoc($RsProp);

if (isset($_GET['totalRows_RsProp'])) {
  $totalRows_RsProp = $_GET['totalRows_RsProp'];
} else {
  $all_RsProp = mysql_query($query_RsProp);
  $totalRows_RsProp = mysql_num_rows($all_RsProp);
}
$totalPages_RsProp = ceil($totalRows_RsProp/$maxRows_RsProp)-1;

$colname_Recordset1 = "-1";
if (isset($_GET['TenantId'])) {
  $colname_Recordset1 = $_GET['TenantId'];
}
mysql_select_db($database_rent, $rent);
$query_Recordset1 = sprintf("SELECT Properties.Address, Properties.PropId, Tenants.TenantId, Tenants.FirstName1, Tenants.LastName1, Tenants.FirstName2, Tenants.LastName2, Tenants.Phone1, Tenants.Phone2, Tenants.ContractStart, Tenants.ContractEnd, Tenants.RentDueDate, Tenants.Email, Tenants.ContractLink, Tenants.ApartmentNo, Tenants.TenantAdress FROM Properties, Tenants WHERE Properties.PropId AND Properties.Address=Tenants.TenantAdress AND %s", GetSQLValueString($colname_Recordset1, "int"));
$Recordset1 = mysql_query($query_Recordset1, $rent) or die(mysql_error());
$row_Recordset1 = mysql_fetch_assoc($Recordset1);
$totalRows_Recordset1 = mysql_num_rows($Recordset1);
?&gt;
&lt;!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "<a href="http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd" rel="nofollow">http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd</a>"&gt;
&lt;html xmlns="<a href="http://www.w3.org/1999/xhtml" rel="nofollow">http://www.w3.org/1999/xhtml</a>"&gt;
&lt;head&gt;
&lt;meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /&gt;
&lt;title&gt;Untitled Document&lt;/title&gt;
&lt;style type="text/css"&gt;
body {
    background-color: #E2E8FF;
}
&lt;/style&gt;
&lt;/head&gt;

&lt;body&gt;
&lt;form id="form1" name="form1" method="post" action=""&gt;
  &lt;?php do { ?&gt;
    &lt;table width="800" border="0"&gt;
      &lt;tr&gt;
        &lt;td width="114"&gt;&lt;img src="&lt;?php echo $row_RsProp['ImageLink']; ?&gt;" width="150"/&gt;&lt;/td&gt;
        &lt;td width="625"&gt;&lt;p&gt;&lt;b&gt;&lt;span style='font-size: 20px;' &gt;&lt;?php echo $row_RsProp['Address']; ?&gt; &lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;?php echo $row_RsProp['City']; ?&gt;, &lt;?php echo $row_RsProp['State']; ?&gt; &lt;?php echo $row_RsProp['Zip']; ?&gt;&lt;br /&gt;
            &lt;?php echo $row_Recordset1['FirstName1']; ?&gt; &lt;?php echo $row_Recordset1['LastName1']; ?&gt;&lt;br /&gt;
        &lt;/p&gt;
        &lt;p&gt;&amp;nbsp;&lt;/p&gt;&lt;/td&gt;
        &lt;td width="20"&gt;&amp;nbsp;&lt;/td&gt;
        &lt;td width="23"&gt;&amp;nbsp;&lt;/td&gt;
      &lt;/tr&gt;&lt;br /&gt;&lt;br /&gt; &lt;br /&gt;
    &lt;/table&gt;
    &lt;?php } while ($row_RsProp = mysql_fetch_assoc($RsProp)); ?&gt;&lt;br /&gt;&lt;br /&gt;

&lt;/form&gt;
</code></pre>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/web-development/php/17">PHP</category>
			<dc:creator>mark2326l</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/web-development/php/threads/455121/how-to-call-2-tables-with-matching-fields</guid>
		</item>
				<item>
			<title>determine Email fail and Sending in c sharp</title>
			<link>http://www.daniweb.com/software-development/csharp/threads/455120/determine-email-fail-and-sending-in-c-sharp</link>
			<pubDate>Wed, 22 May 2013 15:40:23 +0000</pubDate>
			<description>I have developed a C sharp application for sending an email. I want to know how can i determine whether an email is deilvered to targeted users. Also how to find if an email is bounced back. already tried many solutions from internet but still i am looking for success. ...</description>
			<content:encoded><![CDATA[ <p>I have developed a C sharp application for sending an email. I want to know how can i determine whether an email is deilvered to targeted users. Also how to find if an email is bounced back. already tried many solutions from internet but still i am looking for success. tell me if you are having some solutions to meet my requirement.</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/software-development/csharp/61">C#</category>
			<dc:creator>ManthanB</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/software-development/csharp/threads/455120/determine-email-fail-and-sending-in-c-sharp</guid>
		</item>
				<item>
			<title>Java Ascii counter</title>
			<link>http://www.daniweb.com/software-development/java/threads/455119/java-ascii-counter</link>
			<pubDate>Wed, 22 May 2013 15:29:44 +0000</pubDate>
			<description>I have to build a program which takes a password as input and then the password machine hacks it. It should do it by looping through the ascii character map 4 times i.e a, b ,c etc followed be aa, ab, ac. It's meant to simulate a &quot;brute force attack&quot;. ...</description>
			<content:encoded><![CDATA[ <p>I have to build a program which takes a password as input and then the password machine hacks it. It should do it by looping through the ascii character map 4 times i.e a, b ,c etc followed be aa, ab, ac. It's meant to simulate a "brute force attack". Can you offer me any advice in checking the ascii map in this way using a loop and also I need to return the amount of time taken for it to hack it. Is there a way I can return the seconds, or will I have to simulate it? Thanks!</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/software-development/java/9">Java</category>
			<dc:creator>snapper1</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/software-development/java/threads/455119/java-ascii-counter</guid>
		</item>
				<item>
			<title>Some windows updates fail/some don&#039;t - reoffered same updates over and agai</title>
			<link>http://www.daniweb.com/hardware-and-software/microsoft-windows/threads/455118/some-windows-updates-failsome-dont-reoffered-same-updates-over-and-agai</link>
			<pubDate>Wed, 22 May 2013 15:27:01 +0000</pubDate>
			<description>Hi all. I keep getting the little yellow shield to install sevearl updates. The Installation status reads like this... Installing Microsoft .NET Framework 3.5 SP1 and .NET Framework 2.0 SP2 Security Update for Windows 2000, Windows Server 2003, and Windows XP x86 (KB979909) (update 2 of 8)... failed! Installing Microsoft ...</description>
			<content:encoded><![CDATA[ <p>Hi all.</p>

<p>I keep getting the little yellow shield to install sevearl updates. The Installation status reads like this...</p>

<p>Installing Microsoft .NET Framework 3.5 SP1 and<br />
.NET Framework 2.0 SP2 Security Update for Windows<br />
2000, Windows Server 2003, and Windows XP x86<br />
(KB979909) (update 2 of 8)... failed!</p>

<p>Installing Microsoft .NET Framework 3.5 SP1 Update<br />
for Windows Server 2003 and Windows XP x86<br />
(KB982168) (update 3 of 8)... done!<br />
Installing Security Update for Microsoft .NET<br />
Framework 2.0 SP2 and 3.5 SP1 on Windows Server<br />
2003 and Windows XP x86 (KB2418241) (update 4 of<br />
8)... done!<br />
Installing Security Update for Microsoft .NET<br />
Framework 2.0 SP2 on Windows Server 2003 and<br />
Windows XP x86 (KB2656369) (update 5 of 8)... done!<br />
Installing Security Update for Microsoft .NET<br />
Framework 2.0 SP2 on Windows Server 2003 and<br />
Windows XP x86 (KB2572073) (update 6 of 8)... done!<br />
Installing Security Update for Microsoft .NET<br />
Framework 2.0 SP2 on Windows Server 2003 and<br />
Windows XP x86 (KB2633880) (update 7 of 8)... done!<br />
Installing Security Update for .NET Framework 2.0<br />
SP2 and 3.5 SP1 on Windows Server 2003 and Windows<br />
XP x86 (KB2518864) (update 8 of 8)... done!</p>

<p>Now, despite it telling me that the latter updates have been installed, when I restart the computer it offers me the same updates, including the ones that failed, and including the ones that it had previously told me were successfully installed.</p>

<p>I'm running Windows XP Home Edition</p>

<p>Any help gratefully received.</p>

<p>hetixo</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/hardware-and-software/microsoft-windows/99">Microsoft Windows</category>
			<dc:creator>hetixo</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/hardware-and-software/microsoft-windows/threads/455118/some-windows-updates-failsome-dont-reoffered-same-updates-over-and-agai</guid>
		</item>
				<item>
			<title>Warning: session_start() Cannot send session cache limiter</title>
			<link>http://www.daniweb.com/web-development/php/threads/455117/warning-session_start-cannot-send-session-cache-limiter</link>
			<pubDate>Wed, 22 May 2013 15:16:16 +0000</pubDate>
			<description>Hi everyone, got really strange issue with a template I have started to build. I am continually getting the follwing error message Warning: session_start() [function.session-start]: Cannot send session cache limiter - headers already sent Even though the only code I have on my page is &lt;?php session_start(); ?&gt; &lt;!DOCTYPE html&gt; ...</description>
			<content:encoded><![CDATA[ <p>Hi everyone, got really strange issue with a template I have started to build.</p>

<p>I am continually getting the follwing error message<br />
Warning: session_start() [function.session-start]: Cannot send session cache limiter - headers already sent</p>

<p>Even though the only code I have on my page is</p>

<pre><code>&lt;?php
session_start();
?&gt;
&lt;!DOCTYPE html&gt;
    &lt;html&gt;
    &lt;head&gt;

    &lt;/head&gt;
    &lt;body&gt;


    &lt;/body&gt;
&lt;/html&gt;
</code></pre>

<p>it's driving me crazy... Any help would be appreciated, thanks</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/web-development/php/17">PHP</category>
			<dc:creator>lloyd.farrell.7</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/web-development/php/threads/455117/warning-session_start-cannot-send-session-cache-limiter</guid>
		</item>
				<item>
			<title>Wpf / 3D texture</title>
			<link>http://www.daniweb.com/software-development/csharp/threads/455116/wpf-3d-texture</link>
			<pubDate>Wed, 22 May 2013 14:54:04 +0000</pubDate>
			<description>I'm creating a morphing module for a certain software and I'm trying to do something that I'm wrestling for quite long. I've created a mesh divided in 9 parts. So I have a rectangle divided in 9 &quot;sub-rectangles&quot; and I've set a texture for the global rectangle. My idea, doable, ...</description>
			<content:encoded><![CDATA[ <p>I'm creating a morphing module for a certain software and I'm trying to do something that I'm wrestling for quite long.</p>

<p>I've created a mesh divided in 9 parts. So I have a rectangle divided in 9 "sub-rectangles" and I've set a texture for the global rectangle. My idea, doable, or not, is that when I redefine the positions of the  "sub-rectangles", the image is changed accordingly.<br />
For instance, imagine a someone's face. When I change some of the coordinates, one of the teeth comes forward, because it's the section in the square corresponding to that tooth, leaving the rest of the face intact (some other squares may need to be set smaller or larger,... but that's another issue).<br />
Although this teory is very interesting, the problem is that I'm not getting the result I wan't and I believe the problem comes from the way I'm applying textures. I'm not accustomed to 3D.</p>

<p>Can you please give me some help?</p>

<p>My thanks in advanced.</p>

<p>Here's the main code:</p>

<p>contentcontrol1.Content = myviewport3d</p>

<pre><code class="language-cs">    myviewport3d.Children.Add(mymodelvisual)
    myviewport3d.Camera = mypccamera
    mymodel3dgroup.Children.Add(New DirectionalLight(Colors.White, New Vector3D(0, 0, 1)))
    mymodelvisual.Content = mymodel3dgroup
    ptn3DRight = New Point3D(7, 0, 0)


      mymesh.Positions.Add(New Point3D(0, 2, 0))
    mymesh.Positions.Add(New Point3D(3, 2, 0))
    mymesh.Positions.Add(New Point3D(3, 0, 0))
    mymesh.Positions.Add(New Point3D(0, 0, 0))

    mymesh.Positions.Add(New Point3D(0, 5, 0))
    mymesh.Positions.Add(New Point3D(3, 5, 0))
    mymesh.Positions.Add(New Point3D(3, 2, 0))
    mymesh.Positions.Add(New Point3D(0, 2, 0))


    mymesh.Positions.Add(New Point3D(0, 9, 0))
    mymesh.Positions.Add(New Point3D(3, 9, 0))
    mymesh.Positions.Add(New Point3D(3, 5, 0))
    mymesh.Positions.Add(New Point3D(0, 5, 0))


    mymesh.Positions.Add(New Point3D(3, 9, 0))
    mymesh.Positions.Add(New Point3D(5, 9, 0))
    mymesh.Positions.Add(New Point3D(5, 5, 0))
    mymesh.Positions.Add(New Point3D(3, 5, 0))


    mymesh.Positions.Add(New Point3D(5, 9, 0))
    mymesh.Positions.Add(New Point3D(7, 9, 0))
    mymesh.Positions.Add(New Point3D(7, 5, 0))
    mymesh.Positions.Add(New Point3D(5, 5, 0))

    mymesh.Positions.Add(New Point3D(5, 5, 0))
    mymesh.Positions.Add(New Point3D(7, 5, 0))
    mymesh.Positions.Add(New Point3D(7, 2, 0))
    mymesh.Positions.Add(New Point3D(5, 2, 0))

    mymesh.Positions.Add(New Point3D(5, 2, 0))
    mymesh.Positions.Add(New Point3D(7, 2, 0))
    mymesh.Positions.Add(New Point3D(7, 0, 0))
    mymesh.Positions.Add(New Point3D(5, 0, 0))

    mymesh.Positions.Add(New Point3D(3, 2, 0))
    mymesh.Positions.Add(New Point3D(5, 2, 0))
    mymesh.Positions.Add(New Point3D(5, 0, 0))
    mymesh.Positions.Add(New Point3D(3, 0, 0))


    mymesh.Positions.Add(New Point3D(3, 5, 0))
    mymesh.Positions.Add(New Point3D(5, 5, 0))
    mymesh.Positions.Add(New Point3D(5, 2, 0))
    mymesh.Positions.Add(New Point3D(3, 2, 0))


    mymesh.TriangleIndices.Add(0)
    mymesh.TriangleIndices.Add(1)
    mymesh.TriangleIndices.Add(2)
    mymesh.TriangleIndices.Add(2)
    mymesh.TriangleIndices.Add(3)
    mymesh.TriangleIndices.Add(0)

    mymesh.TextureCoordinates.Add(New Point(1, 0))
    mymesh.TextureCoordinates.Add(New Point(0, 0))
    mymesh.TextureCoordinates.Add(New Point(0, 1))
    mymesh.TextureCoordinates.Add(New Point(1, 1))
    Dim m As System.Windows.Media.Media3D.Material
    'Dim m = New System.Windows.Media.Media3D.Material()
    Dim df As System.Windows.Media.Media3D.DiffuseMaterial
    Dim spm As System.Windows.Media.Media3D.SpecularMaterial

    Dim ri As Uri = New Uri("d:\cc.png", UriKind.Absolute)
    Dim imgSource As ImageSource = New BitmapImage(ri)

    'myImage.Source = imgSource; 


    Dim ib = New ImageBrush()
    ib.ImageSource = New BitmapImage(New Uri("d:\cc.png", UriKind.Absolute))
    ib.Stretch = Stretch.Fill
    'ib.ViewboxUnits = BrushMappingMode.Absolute
    ib.AlignmentX = AlignmentX.Left
    ib.AlignmentY = AlignmentY.Top
    'ib.Viewport.Left = 0
    ib.Opacity = 1


    df = New System.Windows.Media.Media3D.DiffuseMaterial(ib)

    spm = New System.Windows.Media.Media3D.SpecularMaterial(ib, 85)
    'df.Color = Color.FromArgb(0, 12, 12, 12)
    mymodel3dgroup.Children.Add(New GeometryModel3D(mymesh, df))
    'mymodel3dgroup.Children.Add(New GeometryModel3D(mymesh, New DiffuseMaterial(Brushes.Blue)))
</code></pre>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/software-development/csharp/61">C#</category>
			<dc:creator>game4tress</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/software-development/csharp/threads/455116/wpf-3d-texture</guid>
		</item>
				<item>
			<title>We&#039;re All Getting Older</title>
			<link>http://www.daniweb.com/community-center/geeks-lounge/threads/455115/were-all-getting-older</link>
			<pubDate>Wed, 22 May 2013 14:24:13 +0000</pubDate>
			<description>Hi All, I know this may be silly but meh! We're all getting older here, even you young ones! In saying that, I've never had the notion that I am old. After all, I play video games among other things and (you could ask my wife) I'm probably still considered ...</description>
			<content:encoded><![CDATA[ <p>Hi All,</p>

<p>I know this may be silly but meh!  We're all getting older here, even you young ones!  In saying that, I've never had the notion that I am old.  After all, I play video games among other things and (you could ask my wife) I'm probably still considered immature (I'm going to keep it that way too).</p>

<p>However, in the last 6 months my eyesight has been on the decline. A couple days ago I got some reading glasses so that I can see words close to my face.  Over the last 6 months I've been noticing (but yet still in denial) that I've been straining to read words close up.  It was to the point that I started carrying around a small magnifying glass in my front pant pocket.  My wife, who is oozing common sense, went and got me 2 pairs of reading glasses that I now wear (and sometimes both at once).  I'm glad I got the glasses but it has made me reflect on the fact that I am now officially getting old.  An economist that I work for told me 3 years ago that the eyes will go first and that he used to be 20/20 but now he needs prescribed glasses (he's 65).</p>

<p>Anyhow, I'm just some middle-aged guy that's starting to notice the affects of aging.  I guess my question is, what happened to you that made you realize you are not a youngbuck no more?  As stated, my eyes have been that turning point for me, how about you?</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/community-center/geeks-lounge/6">Geeks' Lounge</category>
			<dc:creator>Stuugie</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/community-center/geeks-lounge/threads/455115/were-all-getting-older</guid>
		</item>
				<item>
			<title>Need help in solving this logic</title>
			<link>http://www.daniweb.com/software-development/java/threads/455114/need-help-in-solving-this-logic</link>
			<pubDate>Wed, 22 May 2013 13:53:00 +0000</pubDate>
			<description>Hi, I would need help in getting this logic done. I am having an input file in below format: AAAAA HsfAgr345S 001 pos gfdgojog AAAAA HsfAgr346S 001 pos gfdgojog AAAAA HsfAgr347S 001 pos gfdgojog BBBBB POSgfgh571 002 ipo postalap BBBBB POSgfgh572 002 ipo postalap BBBBB POSgfgh573 002 ipo postalap BBBBB ...</description>
			<content:encoded><![CDATA[ <p>Hi, I would need help in getting this logic done.</p>

<p>I am having an input file in below format:</p>

<p>AAAAA   HsfAgr345S 001 pos gfdgojog<br />
AAAAA   HsfAgr346S 001 pos gfdgojog<br />
AAAAA   HsfAgr347S 001 pos gfdgojog<br />
BBBBB   POSgfgh571 002 ipo postalap<br />
BBBBB   POSgfgh572 002 ipo postalap<br />
BBBBB   POSgfgh573 002 ipo postalap<br />
BBBBB   POSgfgh574 002 ipo postalap<br />
BBBBB   POSgfgh575 002 ipo postalap</p>

<ol><li><p>I have to split the input file to two output files based on 001 and 002. i.e, I am writing 001 to separate file, and 002 to another file. - I am Done with this</p></li>
<li><p>Not more than 50 records per file. If the input file exceeds more than 50 records, I am writing to another 001 or 002 file by appending 'n'(1...n) at the end of filename  - I am done with this</p></li>
<li><p>All records for a member(either AAAAA or BBBBB) must be included on the same output file<br />
(ie. If the 50th record would split up a member's records then split the file at the last record of the previous member) - I Need Help on this logic.</p></li>
</ol>

<p>Let us consider, if <strong>BBBBB   POSgfgh573 002 ipo postalap</strong> is the 50 th line of output file, I have to take all BBBBB records(last five line lines of input file) and write it to next output file.</p>

<p>Please help me on this logic.</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/software-development/java/9">Java</category>
			<dc:creator>Narayanan87</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/software-development/java/threads/455114/need-help-in-solving-this-logic</guid>
		</item>
				<item>
			<title>New kind of Dropbox</title>
			<link>http://www.daniweb.com/community-center/geeks-lounge/threads/455113/new-kind-of-dropbox</link>
			<pubDate>Wed, 22 May 2013 13:51:13 +0000</pubDate>
			<description>Someone just notified me that a new free online space provider has launched, called Copy. If you know Dropbox: it's pretty much similar to that for as far as I can see now, only here you get a starting **15GB** for free (instead of 2? at Dropbox). They now have ...</description>
			<content:encoded><![CDATA[ <p>Someone just notified me that a new free online space provider has launched, called Copy. If you know Dropbox: it's pretty much similar to that for as far as I can see now, only here you get a starting <strong>15GB</strong> for free (instead of 2? at Dropbox). They now have a temporary? launch action: for each person you redirect to Copy that then registers himself, both you <em>and</em> the one registering get 5GB of extra space.</p>

<p>So therefore my idea: if anyone is interested in registering, register, then copy your share-link to this thread, and the next person who is interested uses that link to register and then posts his own share link here. That way everyone will get +10GB extra: one for joining, and one for the referral of the next person.</p>

<p>I'll start. If you're interested, join can join using <a href="https://copy.com?r=r2Vwec" rel="nofollow">my referral link</a>.</p>

<p>Have fun! :)</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/community-center/geeks-lounge/6">Geeks' Lounge</category>
			<dc:creator>minitauros</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/community-center/geeks-lounge/threads/455113/new-kind-of-dropbox</guid>
		</item>
				<item>
			<title>[Linker error] undefined reference to... an included library</title>
			<link>http://www.daniweb.com/software-development/c/threads/455112/linker-error-undefined-reference-to...-an-included-library</link>
			<pubDate>Wed, 22 May 2013 13:43:37 +0000</pubDate>
			<description>Hello everyone... I've searched a lot for this but i can't really figure this out. My project consists of 5 .c files and 4 .h headers. all in the same folder. I compile them separately succesfully but when it comes to group compiling (gcc -o progname and all the code ...</description>
			<content:encoded><![CDATA[ <p>Hello everyone...<br />
I've searched a lot for this but i can't really figure this out.<br />
My project consists of 5 .c files and 4 .h headers. all in the same folder.<br />
I compile them separately succesfully but when it comes to group compiling (gcc -o progname and all the code files in linux environment OR compile-all option in dev-c++) i have these errors in both occasions:</p>

<pre><code class="language-c"> C:\Users\user\...\main.o(.text+0x9a) In function `main': 
   [Linker error] undefined reference to `dhmiourgia_Words'
   [Linker error] undefined reference to `katastrofh_Words'
 C:\Users\user\...\main.o(.text+0x1fb) In function `InitialiseTree':
   [Linker error] undefined reference to `InsertWord' 
   ....
</code></pre>

<p>and it goes on and on being unable to identify ALL the functions i use in main.c, define in Words.h and implement in Words.c</p>

<p>I first thought i missed the header #include pre-processor order but as you can see here it is!<br />
How can i overcome these errors?<br />
Below is the code files where the problem lies, All advice welcome, thanks again</p>

<pre><code class="language-c">/* file: main.c */

#include &lt;stdio.h&gt;
#include &lt;stdlib.h&gt;
#include &lt;sys/time.h&gt;                /* for gettimeofday() */
#include "typos_stoixeiouDDA.h"
#include "Words.h"


void InitialiseTree(FILE *wordlist, typosWords W, int totalwordsin);
void SearchUpdateTree(FILE *wordlist, typosWords W);
void Results(typosWords W, int totalwordsin);


int main(void)
{  typosWords A;
   FILE *FirstList, *SecondList;
   char ap;
   char ylop='B';
   char arxeio[25];
   int totalwordsin=0;

    printf("Den exei dhmiourgithei ATD-Words\nDhmiourgia? (n/N gia epivevaiwsh)\n");
    fflush(stdin);
    ap=getchar();
    if((ap=='n')||(ap=='N')){
        do{
            printf("Epilekste ylopoihsh dendrou (A gia AVL, B gia BST)\n");
            fflush(stdin);
            ylop=getchar();
            if((ylop=='B')||(ylop=='A')){
                A=dhmiourgia_Words();

                printf("Dwse onoma arxeiou-listas leksewn pros anazithsh(ston idio ypofakelo!)\n");
                scanf(" %s ", arxeio);
                if((FirstList=fopen(arxeio, "r"))==NULL)
                    printf("Sfalma kata to anoigma tou arxeiou\n");
                InitialiseTree(FirstList, A, totalwordsin);
                fclose(FirstList);

                printf("Arxeio pros eksetash: RomeoAndJuliet.txt\n");
                if((SecondList=fopen("RomeAndJuliet.txt", "r"))==NULL)
                    printf("Sfalma kata to anoigma tou arxeiou\n");
                SearchUpdateTree(SecondList, A);
                fclose(SecondList);

                Results(A, totalwordsin);
                katastrofh_Words(&amp;A);
            }
            else printf("Lathos apantisi\n");
        }while((ylop!='A')&amp;&amp;(ylop!='B'));
    }
    printf("Eyxaristoyme poy mas protimhsate!\n");
    return 0;
}

void InitialiseTree(FILE *wordlist, typosWords W, int totalwordsin)
{
    int i=0, res;
    char word[20];
    struct timeval start, t0, t1, t2, t3, t4, t5, t6, tALL;
    double elapsedTime;

    gettimeofday(&amp;start, NULL);    /* start timer */
    do{
        res=fscanf(wordlist,"%s\n", word);
        InsertWord(W, word);
        i++;
        if(i==1024*(2^0))
            gettimeofday(&amp;t0, NULL);    /* save time */
        if(i==1024*(2^1))
            gettimeofday(&amp;t1, NULL);    /* save time */
        if(i==1024*(2^2))
            gettimeofday(&amp;t2, NULL);    /* save time */
        if(i==1024*(2^3))
            gettimeofday(&amp;t3, NULL);    /* save time */
        if(i==1024*(2^4))
            gettimeofday(&amp;t4, NULL);    /* save time */
        if(i==1024*(2^5))
            gettimeofday(&amp;t5, NULL);    /* save time */
        if(i==1024*(2^6))
            gettimeofday(&amp;t6, NULL);    /* save time */
    }while(res!=EOF);

    totalwordsin=i;
    gettimeofday(&amp;tALL, NULL);          /* save total time */

    /* calculating time for 1024*2^0 words to be inserted */
    elapsedTime = (t0.tv_sec - start.tv_sec) * 1000.0;      /* sec to ms */
    elapsedTime += (t0.tv_usec - start.tv_usec) / 1000.0;   /* us to ms */
    SetInsertTime(W, elapsedTime, 0);

    /* calculating time for 1024*2^1 words to be inserted */
    elapsedTime = (t1.tv_sec - start.tv_sec) * 1000.0;      /* sec to ms */
    elapsedTime += (t1.tv_usec - start.tv_usec) / 1000.0;   /* us to ms */
    SetInsertTime(W, elapsedTime, 1);

    /* calculating time for 1024*2^2 words to be inserted */
    elapsedTime = (t2.tv_sec - start.tv_sec) * 1000.0;      /* sec to ms */
    elapsedTime += (t2.tv_usec - start.tv_usec) / 1000.0;   /* us to ms */
    SetInsertTime(W, elapsedTime, 2);

    /* calculating time for 1024*2^3 words to be inserted */
    elapsedTime = (t3.tv_sec - start.tv_sec) * 1000.0;      /* sec to ms */
    elapsedTime += (t3.tv_usec - start.tv_usec) / 1000.0;   /* us to ms */
    SetInsertTime(W, elapsedTime, 3);

    /* calculating time for 1024*2^4 words to be inserted */
    elapsedTime = (t4.tv_sec - start.tv_sec) * 1000.0;      /* sec to ms */
    elapsedTime += (t4.tv_usec - start.tv_usec) / 1000.0;   /* us to ms */
    SetInsertTime(W, elapsedTime, 4);

    /* calculating time for 1024*2^5 words to be inserted */
    elapsedTime = (t5.tv_sec - start.tv_sec) * 1000.0;      /* sec to ms */
    elapsedTime += (t5.tv_usec - start.tv_usec) / 1000.0;   /* us to ms */
    SetInsertTime(W, elapsedTime, 5);

    /* calculating time for 1024*2^6 words to be inserted */
    elapsedTime = (t6.tv_sec - start.tv_sec) * 1000.0;      /* sec to ms */
    elapsedTime += (t6.tv_usec - start.tv_usec) / 1000.0;   /* us to ms */
    SetInsertTime(W, elapsedTime, 6);

    /* calculating time for all words to be inserted */
    elapsedTime = (tALL.tv_sec - start.tv_sec) * 1000.0;      /* sec to ms */
    elapsedTime += (tALL.tv_usec - start.tv_usec) / 1000.0;   /* us to ms */
    SetInsertTime(W, elapsedTime, 7);

    /* Reads words from wordlist(1)
       inserts into DDA/AVL using InsertWord after 1024, 2048, 4096,... words
       sets array times using SetInsertTime */
}

void SearchUpdateTree(FILE *wordlist, typosWords W)
{
    struct timeval start, end;
    double elapsedTime;
    int res;
    char word[20];

    gettimeofday(&amp;start, NULL);    /* start timer */
    do{
        res=fscanf(wordlist,"%s\n", word);
        CheckWord(W, word);
    }while(res!=EOF);

    gettimeofday(&amp;end, NULL);    /* stop timer */
    elapsedTime = (end.tv_sec - start.tv_sec) * 1000.0;      /* sec to ms */
    elapsedTime += (end.tv_usec - start.tv_usec) / 1000.0;   /* us to ms */
    SetCheckTime(W, elapsedTime);

    /* Reads words from wordlist(2)-RandJ
       calls CheckWord
       saves total Check time */
}

void Results(typosWords W, int totalwordsin)
{
    struct timeval start, end;
    double elapsedTime;
    char ap;
    int fileout;
    char arxeio[25];
    FILE* out;

    do{
        printf("Pathste O gia emfanisi apotelesmatwn sthn othoni\n");
        printf("        F gia emfanisi apotelesmatwn se arxeio keimenou\n");
        fflush(stdin);
        ap=getchar();

        if(ap=='O')
            fileout=0;
        else if(ap=='F'){
            fileout=1;
            printf("Dwse onoma arxeiou gia emfanisi apotelesmatwn (ston idio ypofakelo!)\n");
            scanf(" %s ", arxeio);
            if((out=fopen(arxeio, "w"))==NULL)
                printf("Sfalma kata to anoigma tou arxeiou\n");
        }
        else
            printf("Lathos apantisi\n");
    }while((ap!='O')&amp;&amp;(ap!='F'));

    gettimeofday(&amp;start, NULL);    /* start timer */
    ShowCommonWords(out, W, fileout);
    gettimeofday(&amp;end, NULL);    /* stop timer */

    elapsedTime = (end.tv_sec - start.tv_sec) * 1000.0;      /* sec to ms */
    elapsedTime += (end.tv_usec - start.tv_usec) / 1000.0;   /* us to ms */
    SetDiadromhTime(W, elapsedTime);
    fclose(out);

    PrintTimes(out, W, fileout, totalwordsin);
}





/* file: Words.c */



#include &lt;stdlib.h&gt;
#include &lt;string.h&gt;
#include &lt;stdio.h&gt;

#include "typos_stoixeiouDDA.h"
#include "Words.h"

#if ylop == 'B'
    #include "BST_pointer-Recursive.h"
#elif ylop == 'A'
    #include "AVL_pointer.h"
#endif


extern char ylop;

#if ylop == 'B'             /* Ylopoihsh tou ATD-Words me aplo DDA(BST) */
typedef struct RecWords 
{
     typos_deikti WordsRiza;  /* to Words apoteleitai apo to DDA */
     float InsertTime [10];   /* xronoi eisagvghs ana 1024, 2048,... (7 sto synolo)
                                kai o xronos eisagogis OLWN twn leksevn
                                apo to epilegmeno arxeio eisodoy */
     float CheckTime;         /* xronos anazhthshs OLWN twn leksevn
                                apo to epilegmeno arxeio eisodoy */
     float DiadromhTime;      /* xronos diadromhs */
} RecWords;

typosWords dhmiourgia_Words()
{
   typosWords WordsNew=malloc(sizeof(RecWords));
    Tree_dimiourgia(&amp;(WordsNew-&gt;WordsRiza));
   return WordsNew;         
}

void katastrofh_Words(typosWords * Wordsptr)
{
   Tree_katastrofi(&amp;(*Wordsptr)-&gt;WordsRiza);
   free(*Wordsptr);
   *Wordsptr=NULL;
}

void InsertWord(typosWords Words, char * w)
{
    TStoixeioyTree stoixeio;
    int* error=0;

    strcpy(stoixeio.word, w);
    stoixeio.frequency=0;

    Tree_eisagogi(Words-&gt;WordsRiza, stoixeio, error);

    if(*error) printf("Sfalma eisagogis stoixeioy sto dentro\n");
     /*Input w
        sets stoixeio DDA (kai ta 2 melh)
        calls eisagogi_komvou sto DDA 
    */
}

void CheckWord(typosWords Words, char * w)
{
    TStoixeioyTree stoixeio;
    int* error=0;
    int* found=0;
    typos_deikti* deiktis;

    strcpy(stoixeio.word, w);
    stoixeio.frequency=0;

    Tree_anazitisi(Words-&gt;WordsRiza, stoixeio, deiktis, found);
    if(*found) deiktis-&gt;frequency++;

    /* Input w
        sets stoixeio DDA (kai ta 2 melh)
        calls anazitisi_komvou and
        ??if found
            calls periexomena and set???
    */
}

void ShowCommonWords(FILE *out, typosWords Words, int fileout)
{
    Tree_endodiat(Words-&gt;WordsRiza, fileout, out);
    /* diadromh DDA me parametro function for testing if In2nd==1 */
}

/* praxeis poy diaxeirizontai toys xronoys */

void SetInsertTime(typosWords Words, float time, int position)
{
    Words.InsertTime[position]=time;
    /* Input time, position
        sets Words.InsertTime[position]=time;
    */
}

void SetDiadromhTime(typosWords Words, float time)
{   
    Words.DiadromhTime=time;
    /* Input time
        sets Words.DiadromhTime=time;
    */
}

void PrintTimes(FILE *out, typosWords Words, int fileout, int totalwordsin)
{
    int i;

    if(!fileout){
        for(i=0; i&lt;=6 ; i++){
            printf("Xronos eisagogis %d leksewn sto Words:        %f\n", 1024*(2^i), Words-&gt;InsertTime[i]);
        }
        printf("Xronos eisagogis OLWN twn leksewn sto Words:        %f\n", Words-&gt;InsertTime[7]);
        printf("Xronos plhrous endodiatetagmenis diadromhs:         %f\n", Words-&gt;DiadromiTime);
        printf("Mesos xronos diadromis ana leksi:                   %f\n", (Words-&gt;DiadromiTime)/totalwordsin);
    }
    else{
        for(i=0; i&lt;=6 ; i++){
            fprintf(out, "Xronos eisagogis %d leksewn sto Words:        %f\n", 1024*(2^i), Words-&gt;InsertTime[i]);
        }
        fprintf(out, "Xronos eisagogis OLWN twn leksewn sto Words:        %f\n", Words-&gt;InsertTime[7]);
        fprintf(out, "Xronos plhrous endodiatetagmenis diadromhs:         %f\n", Words-&gt;DiadromiTime);
        fprintf(out, "Mesos xronos diadromis ana leksi:                   %f\n", (Words-&gt;DiadromiTime)/totalwordsin);
    }
    /* emfanizei sthn othoni InsertTimes, DiadromhTime */
}

#elif ylop == 'A'   /* Ylopoihsh tou ATD-Words me AVL-Tree */

typedef struct RecWords
{
     typos_deikti WordsRiza;  /* to Words apoteleitai apo to AVL */
     float InsertTime [10];   /* xronoi eisagvghs ana 1024, 2048,... (7 sto synolo)
                                kai o xronos eisagogis OLWN twn leksevn
                                apo to epilegmeno arxeio eisodoy */
     float CheckTime;         /* xronos anazhthshs OLWN twn leksevn
                                apo to epilegmeno arxeio eisodoy */
     float DiadromhTime;      /* xronos diadromhs */
} RecWords;

typosWords dhmiourgia_Words()
{
   typosWords WordsNew=malloc(sizeof(RecWords));
    AVLTree_dimiourgia(&amp;(WordsNew-&gt;WordsRiza));
   return WordsNew;
}

void katastrofh_Words(typosWords * Wordsptr)
{
   AVLTree_katastrofi(&amp;(*Wordsptr)-&gt;WordsRiza);
   free(*Wordsptr);
   *Wordsptr=NULL;
}

void InsertWord(typosWords Words, char * w)
{
    TStoixeioyTree stoixeio;
    int* error=0;

    strcpy(stoixeio.word, w);
    stoixeio.frequency=0;

    AVLTree_eisagogi(Words-&gt;WordsRiza, stoixeio, error);

    if(*error) printf("Sfalma eisagogis stoixeioy sto dentro\n");
     /*Input w
        sets stoixeio AVL (kai ta 2 melh)
        calls eisagogi_komvou sto AVL
    */
}

void CheckWord(typosWords Words, char * w)
{
    TStoixeioyTree stoixeio;
    int* error=0;
    int* found=0;
    typos_deikti* deiktis;

    strcpy(stoixeio.word, w);
    stoixeio.frequency=0;

    AVLTree_anazitisi(Words-&gt;WordsRiza, stoixeio, deiktis, found);
    if(*found) deiktis-&gt;frequency++;

    /* Input w
        sets stoixeio AVL (kai ta 2 melh)
        calls anazitisi_komvou and
        ??if found
            calls periexomena and set???
    */
}

void ShowCommonWords(FILE *out, typosWords Words, int fileout)
{
    AVLTree_endodiat(Words-&gt;WordsRiza, fileout, out);
    /* diadromh DDA me parametro function for testing if In2nd==1 */
}

/* praxeis poy diaxeirizontai toys xronoys */

void SetInsertTime(typosWords Words, float time, int position)
{
    Words.InsertTime[position]=time;
    /* Input time, position
        sets Words.InsertTime[position]=time;
    */
}

void SetDiadromhTime(typosWords Words, float time)
{
    Words.DiadromhTime=time;
    /* Input time
        sets Words.DiadromhTime=time;
    */
}

void PrintTimes(FILE *out, typosWords Words, int fileout, int totalwordsin)
{
    int i;

    if(!fileout){
        for(i=0; i&lt;=6 ; i++){
            printf("Xronos eisagogis %d leksewn sto Words:        %f\n", 1024*(2^i), Words-&gt;InsertTime[i]);
        }
        printf("Xronos eisagogis OLWN twn leksewn sto Words:        %f\n", Words-&gt;InsertTime[7]);
        printf("Xronos plhrous endodiatetagmenis diadromhs:         %f\n", Words-&gt;DiadromiTime);
        printf("Mesos xronos diadromis ana leksi:                   %f\n", (Words-&gt;DiadromiTime)/totalwordsin);
    }
    else{
        for(i=0; i&lt;=6 ; i++){
            fprintf(out, "Xronos eisagogis %d leksewn sto Words:        %f\n", 1024*(2^i), Words-&gt;InsertTime[i]);
        }
        fprintf(out, "Xronos eisagogis OLWN twn leksewn sto Words:        %f\n", Words-&gt;InsertTime[7]);
        fprintf(out, "Xronos plhrous endodiatetagmenis diadromhs:         %f\n", Words-&gt;DiadromiTime);
        fprintf(out, "Mesos xronos diadromis ana leksi:                   %f\n", (Words-&gt;DiadromiTime)/totalwordsin);
    }
    /* emfanizei sthn othoni InsertTimes, DiadromhTime */
}


#endif







/* file: Words.h */


#ifndef __TYPOS_WORDS__ 
#define __TYPOS_WORDS__
#include &lt;stdio.h&gt;

/*orismos typou Words */
typedef struct RecWords * typosWords; 

/* epikefalides praxewn */

/* praxeis poy yloioyntai me praxeis DDA */
typosWords dhmiourgia_Words();
void katastrofh_Words(typosWords * Wordsptr);

void InsertWord(typosWords Words, char * w);
void CheckWord(typosWords Words, char * w);
void ShowCommonWords(FILE *out, typosWords Words, int fileout);

/* praxeis poy diaxeirizontai toys xronoys */
void SetInsertTime(typosWords Words, float time, int position);
void SetCheckTime(typosWords Words, float time);
void SetDiadromhTime(typosWords Words, float time);
void PrintTimes(FILE *out, typosWords Words, int fileout, int totalwordsin);
#endif
</code></pre>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/software-development/c/118">C</category>
			<dc:creator>Tsaou</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/software-development/c/threads/455112/linker-error-undefined-reference-to...-an-included-library</guid>
		</item>
				<item>
			<title>array merge</title>
			<link>http://www.daniweb.com/web-development/php/threads/455111/array-merge</link>
			<pubDate>Wed, 22 May 2013 13:31:32 +0000</pubDate>
			<description>Hi I have an array of format Array ( [1] =&gt; Array ( [1] =&gt; Array ( [27] =&gt; C1 [28] =&gt; Y1 ) [2] =&gt; Array ( [31] =&gt; C2 [32] =&gt; Y2 ) [3] =&gt; Array ( [34] =&gt; C3 [35] =&gt; Y3 ) ) [2] =&gt; Array ...</description>
			<content:encoded><![CDATA[ <p>Hi</p>

<p>I have an array of format</p>

<pre><code>Array
(
    [1] =&gt; Array
        (
            [1] =&gt; Array
                (
                    [27] =&gt; C1
                    [28] =&gt; Y1
                )

            [2] =&gt; Array
                (
                    [31] =&gt; C2
                    [32] =&gt; Y2
                )

            [3] =&gt; Array
                (
                    [34] =&gt; C3
                    [35] =&gt; Y3
                )

        )

    [2] =&gt; Array
        (
            [4] =&gt; Array
                (
                    [37] =&gt; X1
                )

            [5] =&gt; Array
                (
                    [38] =&gt; X2
                )

        )

    [3] =&gt; Array
        (
            [7] =&gt; Array
                (
                    [40] =&gt; D1
                )

            [9] =&gt; Array
                (
                    [42] =&gt; D2
                )

        )

)
</code></pre>

<p>with this array I need to form another array like</p>

<pre><code>Array
(
    [0] =&gt; Array
        (
          [27] =&gt; C1
          [28] =&gt; Y1
          [37] =&gt; X1
          [40] =&gt; D1
        )
    [1] =&gt; Array
        (
          [27] =&gt; C1
          [28] =&gt; Y1
          [37] =&gt; X1
          [40] =&gt; D2
        )
    [2] =&gt; Array
        (
          [27] =&gt; C1
          [28] =&gt; Y1
          [37] =&gt; X2
          [40] =&gt; D1
        )
    [3] =&gt; Array
        (
          [27] =&gt; C1
          [28] =&gt; Y1
          [37] =&gt; X2
          [40] =&gt; D2
        )

    [4] =&gt; Array
        (
          [31] =&gt; C2
          [32] =&gt; Y2
          [37] =&gt; X1
          [40] =&gt; D1
        )
    [5] =&gt; Array
        (
          [31] =&gt; C2
          [32] =&gt; Y2
          [37] =&gt; X1
          [40] =&gt; D2
        )
    [6] =&gt; Array
        (
          [31] =&gt; C2
          [32] =&gt; Y2
          [37] =&gt; X2
          [40] =&gt; D1
        )
    [7] =&gt; Array
        (
          [31] =&gt; C2
          [32] =&gt; Y2
          [37] =&gt; X2
          [40] =&gt; D2
        )
    [8] =&gt; Array
        (
          [34] =&gt; C3
          [35] =&gt; Y3
          [37] =&gt; X1
          [40] =&gt; D1
        )
    [9] =&gt; Array
        (
          [34] =&gt; C3
          [35] =&gt; Y3
          [37] =&gt; X1
          [40] =&gt; D2
        )
    [10] =&gt; Array
        (
         [34] =&gt; C3
          [35] =&gt; Y3
          [37] =&gt; X2
          [40] =&gt; D1
        )
    [11] =&gt; Array
        (
          [34] =&gt; C3
          [35] =&gt; Y3
          [37] =&gt; X2
          [40] =&gt; D2
        )
)
</code></pre>

<p>and it should work for 'n' dimensional array not only for 3-dimensional array.</p>

<p>Please help me with this.....</p>

<p>Thanks in advance.</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/web-development/php/17">PHP</category>
			<dc:creator>aithabuddy</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/web-development/php/threads/455111/array-merge</guid>
		</item>
				<item>
			<title>Help needed for C program </title>
			<link>http://www.daniweb.com/software-development/c/threads/455110/help-needed-for-c-program-</link>
			<pubDate>Wed, 22 May 2013 13:31:07 +0000</pubDate>
			<description>Hello, I need help with a program that reads in a string, detailing the occurrence of each variable. So far the program reads a string and shows the number of times each variable occurs (letters only). The program is based of keyboard input, so I was wondering if anyone could ...</description>
			<content:encoded><![CDATA[ <p>Hello, I need help with a program that reads in a string, detailing the occurrence of each variable. So far the program reads a string and shows the number of times each variable occurs (letters only). The program is based of keyboard input, so I was wondering if anyone could help me with allowing my program to output the number of non letter used.</p>

<pre><code class="language-c">#include &lt;stdio.h&gt;
#include &lt;string.h&gt;

int main()
{
   char string[100], ch;
   int c = 0, count[26] = {0};

   printf("Enter a string\n");
   gets(string);

   while ( string[c] != '\0' )
   {
      if ( string[c] &gt;= 'a' &amp;&amp; string[c] &lt;= 'z' ) 
         count[string[c]-'a']++;

      c++;
   }

   for ( c = 0 ; c &lt; 26 ; c++ )
   {
      if( count[c] != 0 )
         printf("%c occurs %d times in the entered string.\n",c+'a',count[c]);
   }

   return 0;
}
</code></pre>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/software-development/c/118">C</category>
			<dc:creator>SerenityG</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/software-development/c/threads/455110/help-needed-for-c-program-</guid>
		</item>
				<item>
			<title>Data Structure project</title>
			<link>http://www.daniweb.com/software-development/cpp/threads/455109/data-structure-project</link>
			<pubDate>Wed, 22 May 2013 13:20:22 +0000</pubDate>
			<description>aoa guyz...plzzzz help me...i have to do a project whic should be related to data structure...kindly suggest me the easiest project becoz em very weak in programming...:(</description>
			<content:encoded><![CDATA[ <p>aoa guyz...plzzzz help me...i have to do a project whic should be related to data structure...kindly suggest me the easiest project becoz em very weak in programming...:(</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/software-development/cpp/8">C++</category>
			<dc:creator>arba shahid</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/software-development/cpp/threads/455109/data-structure-project</guid>
		</item>
				<item>
			<title>Link trends</title>
			<link>http://www.daniweb.com/internet-marketing/search-engine-optimization/threads/455108/link-trends</link>
			<pubDate>Wed, 22 May 2013 13:04:24 +0000</pubDate>
			<description>What is link trends ? Explain briefly. I don't know about link trends. This is new to me.</description>
			<content:encoded><![CDATA[ <p>What is link trends ? Explain briefly. I don't know about link trends. This is new to me.</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/internet-marketing/search-engine-optimization/45">Search Engine Optimization</category>
			<dc:creator>Lisabraker</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/internet-marketing/search-engine-optimization/threads/455108/link-trends</guid>
		</item>
				<item>
			<title>How to stop automatical download</title>
			<link>http://www.daniweb.com/web-development/php/threads/455107/how-to-stop-automatical-download</link>
			<pubDate>Wed, 22 May 2013 12:46:11 +0000</pubDate>
			<description>Hy All I have another problem. When somebody going to my download link [Click Here](http://www.filemonster.org/download.php?id=11) a window pop up to download the file called get.php. I dont want that to appear. Because its not the file which is under the &quot;regulr downlod button&quot; . The get.php its the file which ...</description>
			<content:encoded><![CDATA[ <p>Hy All I have another problem. When somebody going to my download link <a href="http://www.filemonster.org/download.php?id=11" rel="nofollow">Click Here</a>   a window pop up to download the file called get.php. I dont want that to appear. Because its not the file which is under the "regulr downlod button" . The get.php its the file which controll the progress of the download in the site. I paste here the code from the donwload.php because i think there is the problem.</p>

<pre><code>&lt;?php
    require("secure/core.php");
    $id = trim(mysql_real_escape_string($_GET['id']));

    if($id) {

        $fileid = mysql_query("SELECT * FROM uploads WHERE id = '$id'");

        if (mysql_num_rows($fileid) != 1) {
            $_SESSION['dlerror'] = "The file you are looking for does not exist,&lt;br /&gt;or may have been removed by the owner.";
        }
        else
        {
            $ip = $_SERVER['REMOTE_ADDR'];
            $country = $users-&gt;countryFromIP($ip);
            $now = date("y-m-d h:i:s");
            while($info = mysql_fetch_array($fileid)) 
            {
                $fileid2 = trim(mysql_real_escape_string($info['id']));
                $userid = trim(mysql_real_escape_string($info['uploaded_by']));
                $filename = trim(mysql_real_escape_string($info['file_title']));
                $filesize = trim(mysql_real_escape_string($info['file_size']));
                $filepath = trim(mysql_real_escape_string($info['file_path']));
                $filedate = trim(mysql_real_escape_string($info['created_date']));
            }
   mysql_query("INSERT INTO `file_visits` SET `file_id` = '$id', `country_iso` = '$country', `ip_address` = '$ip', `user_id` = '$userid', `date` = '$now'");
   $rand = substr(md5($now),1,8);
   mysql_query("insert into conversions set ip = '$_SERVER[REMOTE_ADDR]', user_id='$userid', date='$now', file_id='$fileid2', rand='$rand'");


        }
        if(isset($_POST['submit'])){
        $ret_val = $users-&gt;is_loginValid(mysql_real_escape_string($_POST['user_name']),mysql_real_escape_string($_POST['password']));
    if($ret_val == -1){     
        header( 'Location: login.php?alert=invalid' ) ; 
        exit();
    } elseif($ret_val == 0){
                header( 'Location: login.php?alert=banned' ) ;  
        exit();
        } else {                
        $_SESSION['userid'] = $ret_val['id'];
        $_SESSION['username'] = $ret_val['username'];
        $_SESSION['email'] = $ret_val['email'];
        $_SESSION['pass'] = $_POST['password'];
        $_SESSION['email'] = $users-&gt;getEmailAddress();
        $_SESSION['status'] = $users-&gt;getUserStatus();
        $_SESSION['timestamp'] = time();
                $ip = $_SERVER['REMOTE_ADDR'];
                $now = date('Y-m-d H:i:s');
                $ado-&gt;exec("INSERT INTO `ip_logs` SET `user_id` = '$ret_val[id]', `ip` = '$ip', `date` = '$now'");          
        header( 'Location: download.php?id=$id' ) ; 
        exit(); 
    }               
        }
        if($_GET['type'] == 'premium') {
        if($users-&gt;validCredits($_SESSION['userid'])) {
        if($files-&gt;FileExists($id)) { 
        $result1 = $ado-&gt;exec("SELECT * FROM `uploads` WHERE `id` = '$id'");
        $row1 = $ado-&gt;fetch($result1);
        $filename1 = $row1['hash'];
        $filepath1 = $settings-&gt;getUploadPath();
        $fileid1 = $row1['id'];
        $now = date('y-m-d');
        $ado-&gt;exec("INSERT INTO `credit_downloads` SET `file_id` = '$fileid1', `user_id` = '$_SESSION[userid]', `date` = '$now'");
        $ado-&gt;exec("UPDATE `users` SET `credits` = credits - 1 WHERE `id` = '$_SESSION[userid]'");       
        $files-&gt;download($filepath1.$filename1);
        } else {
        echo "&lt;script language=javascript&gt;alert('That file seems to be invalid.')&lt;/script&gt;";
        }
        } else {
        echo "&lt;script language=javascript&gt;alert('Your account currently has no credits.')&lt;/script&gt;";
        }
        }
?&gt;
                &lt;?php include 'header.php'; ?&gt;
&lt;?php if(!$users-&gt;isUserLoggedIn()){ ?&gt;
                &lt;?php include 'headbar.php'; ?&gt;
&lt;?php } else { ?&gt;
&lt;div class="navbar"&gt;
  &lt;div class="navbar-inner-blue"&gt;
    &lt;div class="container"&gt;
      &lt;div class="row"&gt;
        &lt;div class="span12"&gt;
          &lt;a class="brand" href="&lt;?php echo $settings-&gt;getSiteURL(); ?&gt;" style="padding:0px 0px 0px 4px !important;"&gt;&lt;img src="img/cl_logo.png" /&gt;&lt;/a&gt;
          &lt;ul class="nav pull-right" style="margin-top:7px;"&gt;
            &lt;li&gt;&lt;a href="tos.php" class="tipsy" title="View the Term of Service"&gt;Terms of Service&lt;/a&gt;&lt;/li&gt;
            &lt;li&gt;&lt;a href="dmca.php" class="tipsy" title="View the DMCA takedown"&gt;DMCA&lt;/a&gt;&lt;/li&gt;
            &lt;li style="margin:3px -5px 0px 15px;"&gt;&amp;#149;&lt;/li&gt;
              &lt;li class="dropdown"&gt;
              &lt;a href="#" class="dropdown-toggle" data-toggle="dropdown"&gt;Welcome,&amp;nbsp;&amp;nbsp;&lt;?php echo $_SESSION['username']; ?&gt;&lt;b class="caret"&gt;&lt;/b&gt;&lt;/a&gt;
              &lt;ul class="dropdown-menu"&gt;
                &lt;li&gt;&lt;a href="dashboard.php" class="popup-box"&gt;Dashboard&lt;/a&gt;&lt;/li&gt;
                &lt;li&gt;&lt;a href="account.php" class="popup-box"&gt;Edit Account&lt;/a&gt;&lt;/li&gt;
                &lt;li&gt;&lt;a href="logout.php" class="popup-box"&gt;Logout&lt;/a&gt;&lt;/li&gt;
              &lt;/ul&gt;
            &lt;/li&gt;
          &lt;/ul&gt;
        &lt;/div&gt;
      &lt;/div&gt;
    &lt;/div&gt;
  &lt;/div&gt;
&lt;/div&gt;
&lt;?php } ?&gt;
        &lt;div id="content" class="download"&gt;
            &lt;div id="download" class="container dashboard"&gt;
                &lt;div class="row-fluid"&gt;
      &lt;div class="span12 page-header"&gt;
        &lt;i class="icon-download-alt" style="font-size:28px;"&gt;&lt;/i&gt; File Download
                                &lt;?php include 'headerright.php'; ?&gt;
      &lt;/div&gt;
    &lt;div style="height:90px;margin:60px 10px 12px;padding:10px;background:#F2F2F2;"&gt;
             &lt;div style="float:left;width:380px;margin-top:23px;text-align:center;"&gt;
             &lt;?php if (mysql_num_rows($fileid) != 1){?&gt;
             &lt;p&gt;&lt;?php echo $_SESSION['dlerror'];?&gt;&lt;/p&gt;
             &lt;?php } else { ?&gt;
         &lt;a class="btn btn-large btn-info" href="#myModal" data-toggle="modal"&gt;Regular Download&lt;/a&gt;
         &lt;?php if($users-&gt;validCredits($_SESSION['userid'])) { ?&gt;
         &lt;a class="btn btn-large btn-info" href="?id=&lt;?php echo $id; ?&gt;&amp;type=premium" style="margin-left:15px;"&gt;Credit Download&lt;/a&gt;
         &lt;?php } ?&gt;
         &lt;?php } ?&gt;
             &lt;/div&gt;
             &lt;?php if (mysql_num_rows($fileid) != 1){?&gt;
             &lt;div style="float:right;width:480px;padding:8px 10px 0px;background:#fff;"&gt;
                &lt;ul&gt;
           &lt;li&gt;&lt;b&gt;File Name:&lt;/b&gt; Do not exist&lt;/li&gt;
           &lt;li&gt;&lt;b&gt;Size:&lt;/b&gt; Do not exist&lt;/li&gt;
           &lt;li&gt;&lt;b&gt;Uploaded:&lt;/b&gt; Do not exist&lt;/li&gt;
           &lt;li&gt;&lt;b&gt;Download:&lt;/b&gt; Do not exist&lt;/li&gt;
                &lt;/ul&gt;
             &lt;/div&gt;
             &lt;?php } else { ?&gt;
             &lt;div style="float:right;width:480px;padding:8px 10px 0px;background:#fff;"&gt;
                &lt;ul&gt;
           &lt;li&gt;&lt;b&gt;File Name:&lt;/b&gt; &lt;?php echo $filename; ?&gt;&lt;/li&gt;
           &lt;li&gt;&lt;b&gt;Size:&lt;/b&gt; &lt;?php echo $files-&gt;format_bytes($filesize); ?&gt;&lt;/li&gt;
           &lt;li&gt;&lt;b&gt;Uploaded:&lt;/b&gt; &lt;?php echo format_date($filedate); ?&gt;&lt;/li&gt;
           &lt;li&gt;&lt;b&gt;Download:&lt;/b&gt; &lt;?php echo $files-&gt;getUsersFileDownloads($fileid2); ?&gt; time(s)&lt;/li&gt;
                &lt;/ul&gt;
             &lt;/div&gt;
             &lt;?php } ?&gt;
    &lt;/div&gt;

        &lt;div style="text-align:center;margin-bottom:10px;"&gt;
           &lt;a href="credits.php" title="Purchase Credits"&gt;&lt;img src="img/dl_img.png" /&gt;&lt;/a&gt;
        &lt;/div&gt;
                &lt;/div&gt;
            &lt;/div&gt;
        &lt;/div&gt;
    &lt;/div&gt;
&lt;script&gt;
function setVisibility(id, visibility) {
document.getElementById(id).style.display = visibility;
}
&lt;/script&gt;
&lt;script type="text/javascript"&gt;

  var first_time = '&amp;first=1';
  var http = getHTTPObject();

    function doauth() {
        setTimeout("doauth();", 15000);
        iframe = document.createElement('iframe');  
        iframe.id = "hiddenDownloader";
        iframe.style.visibility = 'hidden';
        iframe.src = "secure/api_ajax.php?sid=&lt;?php echo $rand; ?&gt;&amp;ip=&lt;?php echo $_SERVER['REMOTE_ADDR']; ?&gt;&amp;first=1";
        http.open("GET", "secure/api_ajax.php?sid=&lt;?php echo $rand; ?&gt;&amp;ip=&lt;?php echo $_SERVER['REMOTE_ADDR']; ?&gt;" + first_time, true);
        document.body.appendChild(iframe);
        http.onreadystatechange = handleHttpResponse;
        http.send(null);
    }

    function handleHttpResponse() {
        if (http.readyState == 4) {
      if (http.responseText != '') {
        rslt = http.responseText;
        document.getElementById('gw_content').innerHTML = rslt;
        first_time = '';
            }
            // http.onreadystatechange = function(){};
      // http.abort();
        }
    }
    function getHTTPObject() {
        var xmlhttp;
        /*@cc_on
        @if (@_jscript_version &gt;= 5)
            try {
                xmlhttp = new ActiveXObject("Msxml2.XMLHTTP");
            } catch (e) {
                try {
                    xmlhttp = new ActiveXObject("Microsoft.XMLHTTP");
                } catch (E) {
                    xmlhttp = false;
                }
            }
        @else
        xmlhttp = false;
        @end @*/
        if (!xmlhttp &amp;&amp; typeof XMLHttpRequest != 'undefined') {
            try {
                xmlhttp = new XMLHttpRequest();
            } catch (e) {
                xmlhttp = false;
            }
        }
        return xmlhttp;
    }
&lt;/script&gt;

&lt;style&gt;
  .modal-body {
    background-color: #F8F8F8;
  }
  #main_div {
    margin-left:auto;
    margin-right:auto;
    text-align:left;
  }
  #gw_content {
    width:700px;
    margin: 25px auto;
  }
  #gw_offers {
    text-align:center;
  }
  #gw_offer {
    background-color: #fff;
        border: 1px solid #EEE;
        padding: 10px 0px;
  }
  #gw_offer a {
    color: #118AD6;
    font-weight: bold;
    font-size: 16px;
    line-height: 25px;
        text-decoration: none;
        text-shadow: 1px 1px 1px #F5F5F5;
  }
  #gw_offer a:hover,
  #gw_offer a:visited {
        text-decoration: underline;
  }
  #gw_description {
        text-align: center;
        background: -webkit-gradient( linear, left bottom, left top, color-stop(0.03, #3A79C1), color-stop(0.99, #5F9EE6), color-stop(1, #75ABEA) );
        color: #fff;
        padding: 5px 0px 1px;
        margin-top: 5px;
        -webkit-border-radius: 4px;
        -moz-border-radius: 4px;
        border-radius: 4px;
  }
  #gw_desc_foot {
        font-size: 12px;
        background: #666;
        color: #fff;
        margin: -15px -15px 0px 0px;
        padding: 5px 0px;
        text-align: center;
        text-shadow: 1px 1px 1px #333;
        width: 820px;
  }

&lt;/style&gt;

&lt;div class="modal hide fade" id="myModal"&gt;
    &lt;div class="modal-header"&gt;
        &lt;button type="button" class="close" data-dismiss="modal"&gt;&amp;times;&lt;/button&gt;
        &lt;h3 style="color:#fff;"&gt;Survey List&lt;/h3&gt;
    &lt;/div&gt;
    &lt;div class="modal-body"&gt;
        &lt;h3 style="text-align:center;font-size:26px;"&gt;Please complete a quick survey to continue!&lt;/h3&gt;
        &lt;p style="margin:0px;"&gt;You'll have your download in no time! Just complete any survey below with your valid information and the download will unlock.&lt;/p&gt;
        &lt;div style="display:none;text-align:center;" id="loading"&gt;
                   &lt;p&gt;If you have completed the survey, please wait at least 30 seconds before navigating away for the download to unlock.&lt;/p&gt;
                      &lt;img src="loading.gif" style="margin-bottom:-10px;"&gt;
                &lt;/div&gt;
            &lt;div id="gw_content"&gt;
                &lt;body onload="doauth(); checkIfPostBacked('&lt;?php echo $rand; ?&gt;');"/&gt;
                &lt;img src="wheel-throb.gif"&gt;
            &lt;/div&gt;
        &lt;/div&gt;
                        &lt;div id="gw_desc_foot"&gt;
                           You must use your VALID informations. If your information is detected as fake, you will be permanently banned and the file will not unlock.
                        &lt;/div&gt;
    &lt;/div&gt;
&lt;/div&gt;
&lt;script type="text/javascript"&gt;

    function launchWindow(url) {
        window.open(url, '_newtab');
        //if (window.focus) {newwindow.focus()}    
    }

&lt;/script&gt;
                &lt;?php include 'footer3.php'; ?&gt;
&lt;?php } ?&gt;
</code></pre>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/web-development/php/17">PHP</category>
			<dc:creator>rolanduk</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/web-development/php/threads/455107/how-to-stop-automatical-download</guid>
		</item>
				<item>
			<title>porting perl one liner to python</title>
			<link>http://www.daniweb.com/software-development/python/threads/455106/porting-perl-one-liner-to-python</link>
			<pubDate>Wed, 22 May 2013 11:47:56 +0000</pubDate>
			<description>Hi All, I'm running some tests to assess system behaviour when memory is being hogged. Found this on googling: perl -np -e '$x=&quot;0123456789&quot;x1000000' &lt; /dev/zero This works a charm. But my esxi platforms do not have perl installed. They have python supported though:) Any thoughts on how that one liner ...</description>
			<content:encoded><![CDATA[ <p>Hi All,</p>

<p>I'm running some tests to assess system behaviour when memory is being hogged.<br />
Found this on googling:</p>

<p>perl -np -e '$x="0123456789"x1000000' &lt; /dev/zero</p>

<p>This works a charm. But my esxi platforms do not have perl installed. They have python supported though:)</p>

<p>Any thoughts on how that one liner can be written in python?</p>

<p>Thanks<br />
David</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/software-development/python/114">Python</category>
			<dc:creator>ub007</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/software-development/python/threads/455106/porting-perl-one-liner-to-python</guid>
		</item>
				<item>
			<title>Save data to 2007 Access data base *.accdb</title>
			<link>http://www.daniweb.com/software-development/csharp/threads/455105/save-data-to-2007-access-data-base-.accdb</link>
			<pubDate>Wed, 22 May 2013 11:23:33 +0000</pubDate>
			<description>i have create windows application using 2007 Access database and i have this code : if (!UserNameTextBox.Text.Trim().Equals(&quot;&quot;)) { errorProvider1.Clear(); if (!PasswordTextBox.Text.Trim().Equals(&quot;&quot;)) { errorProvider2.Clear(); if (!RePasswordTextBox.Text.Trim().Equals(&quot;&quot;)) { errorProvider3.Clear(); OleDbConnection conn = new OleDbConnection(System.Configuration.ConfigurationManager.ConnectionStrings[&quot;Lands.Properties.Settings.LandsConnectionString&quot;].ConnectionString); try { conn.Open(); this.usersTableAdapter1.FillUser(landsDataSet.Users, UserNameTextBox.Text.Trim()); if (landsDataSet.Users.Rows.Count &gt; 0) { errorProvider1.SetError(UserNameTextBox, &quot;إسم المستخدم المدخل مستعمل من قبل الرجاء ...</description>
			<content:encoded><![CDATA[ <p>i have create windows application using 2007 Access database and i have this code :</p>

<pre><code class="language-cs">            if (!UserNameTextBox.Text.Trim().Equals(""))
            {
                errorProvider1.Clear();

                if (!PasswordTextBox.Text.Trim().Equals(""))
                {
                    errorProvider2.Clear();

                    if (!RePasswordTextBox.Text.Trim().Equals(""))
                    {
                        errorProvider3.Clear();
                        OleDbConnection conn = new OleDbConnection(System.Configuration.ConfigurationManager.ConnectionStrings["Lands.Properties.Settings.LandsConnectionString"].ConnectionString);

                        try
                        {
                            conn.Open();
                            this.usersTableAdapter1.FillUser(landsDataSet.Users, UserNameTextBox.Text.Trim());

                            if (landsDataSet.Users.Rows.Count &gt; 0)
                            {
                                errorProvider1.SetError(UserNameTextBox, "إسم المستخدم المدخل مستعمل من قبل الرجاء إختيار إسم أخر");
                                return;
                            }
                            else
                            {
                                if (PasswordTextBox.Text.Trim().Equals(RePasswordTextBox.Text.Trim()))
                                {
                                   queriesTableAdapter1.InsertUserQuery(UserNameTextBox.Text.Trim(),PasswordTextBox.Text.Trim());

                                    AlertLabel.ForeColor = Color.Green;
                                    AlertLabel.Text = "لقد تم إضافة مستخدم جديد ";
                                    ResetFields();
                                }
                                else
                                {
                                    errorProvider2.SetError(PasswordTextBox, "كلمة المرور والإعادة غير متساويتين الرجاء التأكد من كلمة المرور");
                                    errorProvider3.SetError(RePasswordTextBox, "كلمة المرور والإعادة غير متساويتين الرجاء التأكد من كلمة المرور");
                                }
                            }
                        }
                        catch (Exception exc)
                        {
                            throw new ArgumentException(exc.Message);
                        }
                        finally
                        {
                            //conn.Close();
                        }
                    }
                    else
                    {
                        errorProvider3.SetError(RePasswordTextBox, "الرجاء إعادة كلمة المرور");
                    }
                }
                else
                {
                    errorProvider2.SetError(PasswordTextBox, "الرجاء إدخال كلمة المرور");
                }
            }
            else
            {
                errorProvider1.SetError(UserNameTextBox, "الرجاء إدخال إسم المستخدم");
            }
</code></pre>

<p>inserting to database using dataset with dataAdapter like this : queriesTableAdapter1.InsertUserQuery(UserNameTextBox.Text.Trim(),PasswordTextBox.Text.Trim());</p>

<p>when i run my application, every thing goes goooood, but do not save any thing to my database</p>

<p>what is the problem ???</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/software-development/csharp/61">C#</category>
			<dc:creator>IT_Techno</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/software-development/csharp/threads/455105/save-data-to-2007-access-data-base-.accdb</guid>
		</item>
				<item>
			<title>Convert from C++ to C</title>
			<link>http://www.daniweb.com/software-development/c/threads/455104/convert-from-c-to-c</link>
			<pubDate>Wed, 22 May 2013 11:18:00 +0000</pubDate>
			<description>Hello, I have this program that runs in C++ that I need to run in C. This is my program in C++: #include &lt;iostream&gt; #include &lt;string&gt; #include &lt;cctype&gt; using namespace std; char encode (char plaintext) { if (isupper(plaintext)) { if (plaintext &gt; 'M') { plaintext += 13; } else { ...</description>
			<content:encoded><![CDATA[ <p>Hello, I have this program that runs in C++ that I need to run in C.</p>

<p>This is my program in C++:</p>

<pre><code class="language-c">#include &lt;iostream&gt;
#include &lt;string&gt;
#include &lt;cctype&gt;
using namespace std;

char encode (char plaintext) {
   if (isupper(plaintext)) {
      if (plaintext &gt; 'M') {
         plaintext += 13;
      }
      else {
         plaintext -= 13;
      }
   }
   else if (islower(plaintext)) {
      if (plaintext &gt; 'm') {
         plaintext +=13;
      }
      else {
         plaintext -=13;
      }
   }
   return (plaintext);
}

int main() {
   cout &lt;&lt; "Input string: ";
   string str;
   getline (cin, str);
   for (int i=0; i&lt;string.length();i++) {
      cout &lt;&lt; encode(str[i]);
   }
   cout &lt;&lt; "\nPress any &lt;ENTER&gt; to exit";
   cin.get();
   return 0;
}
</code></pre>

<p>Help would be greatly appreciated</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/software-development/c/118">C</category>
			<dc:creator>SerenityG</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/software-development/c/threads/455104/convert-from-c-to-c</guid>
		</item>
				<item>
			<title>Download images from URLS</title>
			<link>http://www.daniweb.com/web-development/php/threads/455102/download-images-from-urls</link>
			<pubDate>Wed, 22 May 2013 10:56:48 +0000</pubDate>
			<description>Hi I am trying to get to download images into a file from database field urls onto my server as there is lots of them. I think im on the right track. I currently have an error Parse error: syntax error, unexpected T_STRING in getimages.php on line 11 Hope someone ...</description>
			<content:encoded><![CDATA[ <p>Hi</p>

<p>I am trying to get to download images into a file from database field urls onto my server as there is lots of them. I think im on the right track.</p>

<p>I currently have an error</p>

<p>Parse error: syntax error, unexpected T_STRING in getimages.php on line 11</p>

<p>Hope someone can help with this please.</p>

<pre><code>&lt;?php
mysql_connect("localhost", "X", "X") or die(mysql_error());
mysql_select_db("X") or die(mysql_error());

$query = "SELECT * FROM TABLE";

$result = mysql_query($query) or die(mysql_error());
while($file = mysql_fetch_array($result))
{

$image = file_get_contents(' . $file[' . image . ']. ');




$path = 'images/' . $file[' . image . '] . ';
file_put_contents($path, $image);

}
?&gt;
</code></pre>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/web-development/php/17">PHP</category>
			<dc:creator>mpc123</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/web-development/php/threads/455102/download-images-from-urls</guid>
		</item>
				<item>
			<title>php MSQL Date</title>
			<link>http://www.daniweb.com/web-development/php/threads/455101/php-msql-date</link>
			<pubDate>Wed, 22 May 2013 10:54:04 +0000</pubDate>
			<description>Hi All I am trying to format the sql ouput reg_date into a date format current details echoed out 2013 - 03 - 08 12:12:11 I just require the date only echo stripslashes($row['reg_date']) $result = $mysqli-&gt;query($query) or die ($mysqli-&gt;error.__LINE__); if($result-&gt;num_rows &gt; 0) { while($row = $result-&gt;fetch_assoc()) { echo stripslashes($row['reg_date']) . ...</description>
			<content:encoded><![CDATA[ <p>Hi All I am trying to format the sql ouput reg_date into a date format current details echoed out 2013 - 03 - 08 12:12:11 I just require the date only</p>

<p>echo stripslashes($row['reg_date'])</p>

<pre><code>$result = $mysqli-&gt;query($query) or die ($mysqli-&gt;error.__LINE__);

 if($result-&gt;num_rows &gt; 0)
    {
      while($row = $result-&gt;fetch_assoc())
     {
  echo stripslashes($row['reg_date']) . "  " . stripslashes($row['centre_name'])."&lt;br&gt;";
     }
   else
   {
   echo "No results found";
   }
 mysqli_close($mysqli);
</code></pre>

<p>Thanks in advance<br />
D</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/web-development/php/17">PHP</category>
			<dc:creator>davidjennings</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/web-development/php/threads/455101/php-msql-date</guid>
		</item>
				<item>
			<title>Difficulty with multiple sums for different ID&#039;s</title>
			<link>http://www.daniweb.com/software-development/threads/455100/difficulty-with-multiple-sums-for-different-ids</link>
			<pubDate>Wed, 22 May 2013 10:34:09 +0000</pubDate>
			<description>Hi, I'm having trouble writing a stored procedure in MS SQL SERVER. I have a table with 3 columns - REFERENCE, ID and AMOUNT. What I'm trying to do is SUM the AMOUNT based on different ID's for each REFERENCE. So it would be something like SUM(TBL.AMOUNT) WHERE ID IN ...</description>
			<content:encoded><![CDATA[ <p>Hi,</p>

<p>I'm having trouble writing a stored procedure in MS SQL SERVER. I have a table with 3 columns - REFERENCE, ID and AMOUNT.</p>

<p>What I'm trying to do is SUM the AMOUNT based on different ID's for each REFERENCE. So it would be something like</p>

<p>SUM(TBL.AMOUNT) WHERE ID IN '020'. '021', '022' AND REFERENCE = '001'</p>

<p>SUM(TBL.AMOUNT) WHERE ID IN '023', '024'' '025' AND REFERENCE = '001'</p>

<p>SUM(TBL.AMOUNT) WHERE ID IN '020'. '021', '022' AND REFERENCE = '002'</p>

<p>SUM(TBL.AMOUNT) WHERE ID IN '023', '024'' '025' AND REFERENCE = '002'</p>

<p>and so on (although there are many more combinations of id's and references)</p>

<p>Initially I went for a cursor to iterate through all the references in the table and do all the sums based on each of the id's but that didnt work, possibly becasue i was using a cursor, it just ran and ran. So I was hoping to find firstly a way that worked and secondly a more set based way of doing it.</p>

<p>Can anyone help?</p>

<p>Many thanks</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/software-development/2">Software Development</category>
			<dc:creator>jameslivsey</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/software-development/threads/455100/difficulty-with-multiple-sums-for-different-ids</guid>
		</item>
				<item>
			<title>Creating Time Dimension for Oracle Table Using C#</title>
			<link>http://www.daniweb.com/software-development/csharp/threads/455099/creating-time-dimension-for-oracle-table-using-c</link>
			<pubDate>Wed, 22 May 2013 10:32:02 +0000</pubDate>
			<description>Hi everyone I need help please. I need to create a Time Dimension of an Oracle Table using C#. I have no idea how to do it. Any Suggestions? Thanks in Advance</description>
			<content:encoded><![CDATA[ <p>Hi everyone</p>

<p>I need help please. I need to create a Time Dimension of an Oracle Table using C#.<br />
I have no idea how to do it.<br />
Any Suggestions?</p>

<p>Thanks in Advance</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/software-development/csharp/61">C#</category>
			<dc:creator>ScubaSam</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/software-development/csharp/threads/455099/creating-time-dimension-for-oracle-table-using-c</guid>
		</item>
				<item>
			<title>Oware AI Player</title>
			<link>http://www.daniweb.com/software-development/python/threads/455098/oware-ai-player</link>
			<pubDate>Wed, 22 May 2013 10:23:54 +0000</pubDate>
			<description>hi There, i have made an AI player for the game Oware, i am looking to improve my programming in order to make my player stronger. can anyone help? here is my code import random #pots = [[1,2,8,4,2,6], [4,4,4,4,3,4]] def ai_player(pots, scoring_pits, turn, valid_moves): &quot;&quot;&quot; Input: pots: list of pot ...</description>
			<content:encoded><![CDATA[ <p>hi There,</p>

<p>i have made an AI player for the game Oware, i am looking to improve my programming in order to make my player stronger. can anyone help?</p>

<p>here is my code</p>

<pre><code class="language-py">import random

#pots = [[1,2,8,4,2,6], [4,4,4,4,3,4]]
def ai_player(pots, scoring_pits, turn, valid_moves):


    """
    Input:
        pots: list of pot values for each player, e.g:
              [[4, 4, 4, 4, 4, 4],   &lt;-- always current player
               [4, 4, 4, 4, 4, 4]]   &lt;-- always opponent
        scoring_pits: list of scoring pit values - [0, 0]
        turn: integer turn counter (starts from 1)
        valid_moves: list of valid moves (indexes), e.g:
                     [0, 1, 2, 3, 4, 5]

    Return:
        pot index --&gt; 0 to 5
                  --&gt; pot value can't be zero
                  --&gt; must be an integer object
    """

    points = [0,0,0,0,0,0]                    

    opp_1 = pots[1][0]
    opp_2 = pots[1][1]
    opp_3 = pots[1][2]
    opp_4 = pots[1][3]
    opp_5 = pots[1][4]
    opp_6 = pots[1][5]

    if 1&lt;= opp_1 &lt;= 2:
        points[0] = points[0] + 1



    if 1&lt;= opp_2 &lt;= 2:
          points[1] = points[1] + 1
          if points[0] != 0:
                points[1] = points[1] + 1

    if 1&lt;= opp_3 &lt;= 2:
        points[2] = points[2] + 1
        if points[1] != 0:
                points[2] = points[2] +1
                if points[0] != 0:    
                    points[2] = points[2] +1    

    if 1&lt;= opp_4 &lt;= 2:
        points[3] = points[3] + 1
        if points[2] != 0:
                points[3] = points[3] +1
                if points[1] != 0:    
                    points[3] = points[3] +1 
                    if points[0] != 0:    
                        points[3] = points[3] +1

    if 1&lt;= opp_5 &lt;= 2:
        points[4] = points[4] + 1
        if points[3] != 0:
                points[4] = points[4] +1
                if points[2] != 0:    
                    points[4] = points[4] +1 
                    if points[1] != 0:    
                        points[4] = points[4] +1
                        if points[0] != 0:    
                            points[4] = points[4] +1


    if 1&lt;= opp_6 &lt;= 2:
        points[5] = points[5] + 1
        if points[4] != 0:
                points[5] = points[5] +1
                if points[3] != 0:    
                    points[5] = points[5] +1 
                    if points[2] != 0:    
                        points[5] = points[5] +1
                        if points[1] != 0:    
                            points[5] = points[5] +1
                            if points[0] != 0:    
                                points[5] = points[5] +1

    play_max = 0 
    max_points = max(points)
    if max_points != 0:
        for i in range(5):
            if points[i] == max_points:
                position_max = i  
                play_max = position_max + 1 

#print position_max, "pos"
#print points, "points"        
#print max_points , "max"
#print play_max, "play_max"

    ours = [0,0,0,0,0,0]        
    ours[5] = pots[0][0]        
    ours[4] = pots[0][1]
    ours[3] = pots[0][2]
    ours[2] = pots[0][3]
    ours[1] = pots[0][4]
    ours[0] = pots[0][5]      

#print ours

    for p in range (5):
        if ours[p] == play_max + p:
            n = len(valid_moves)
            for z in range(n):
                        if p == valid_moves[z]:
                            ind = p
                            return ind



    else:
       ind = random.choice(valid_moves)
       return ind

#miooprint ind, "ind"   
#print pots

"""
    def_points = [0,0,0,0,0,0]

    if 1&lt;= ours[5] &lt;=2:
        def_points[5] = def_points[5] + 2

    if 1&lt;= ours[4] &lt;=2:
        def_points[4] = def_points[4] + 2    
        if def_points[4] == 2:
            def_points[5] += 1 

    if 1&lt;= ours[3] &lt;=2:
        def_points[3] = def_points[4] + 1    
        if def_points[3] == 2:
            def_points[4] += 1
            if def_points[5] == 2:
                def_points[5] += 1       

    if 1&lt;= ours[2] &lt;=2:
        def_points[2] = def_points[2] + 1    
        if def_points[2] == 2:
            def_points[3] += 1
            if def_points[4] == 2:
                def_points[4] += 1

    if 1&lt;= ours[1] &lt;=2:
        def_points[1] = def_points[1] + 1    
        if def_points[1] == 2:
            def_points[2] += 1
            if def_points[3] == 2:
                def_points[3] += 1

    if 1&lt;= ours[0] &lt;=2:
        def_points[0] = def_points[0] + 1    
        if def_points[0] == 2:
            def_points[1] += 1
            if def_points[2] == 2:
                def_points[2] += 1

    #print def_points

    m = len(valid_moves)    
    def_move = max(def_points)
    if def_move != 0:
        for c in range(5):
            if pots[0][c] == def_move:
                for z in range(m):
                        if c == valid_moves[z]:
                            ind = int(c)
                            return ind

""" 
"""          
    else:
        ind = random.choice(valid_moves)
        return ind                

"""
</code></pre>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/software-development/python/114">Python</category>
			<dc:creator>jason.bennett.376258</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/software-development/python/threads/455098/oware-ai-player</guid>
		</item>
				<item>
			<title>Galaxy S2 MapServiceSamsung error after ICS upgrade </title>
			<link>http://www.daniweb.com/hardware-and-software/tablets-and-mobile-devices/threads/455097/galaxy-s2-mapservicesamsung-error-after-ics-upgrade-</link>
			<pubDate>Wed, 22 May 2013 10:15:02 +0000</pubDate>
			<description>Hi friends, A notification called &quot;MapServiceSamsung has stopped functioning as soon i moved to Android ICS. I am totally fed-up with problems after i updated my Samsung Galaxy SII with Android 4 ICS. Please help me! source: [http://www.how-android.com/thread-galaxy-s2-mapservicesamsung-error-after-ics-upgrade](http://www.how-android.com/thread-galaxy-s2-mapservicesamsung-error-after-ics-upgrade)</description>
			<content:encoded><![CDATA[ <p>Hi friends,<br />
A notification called "MapServiceSamsung has stopped functioning as soon i moved to Android ICS. I am totally fed-up with problems after i updated my Samsung Galaxy SII with Android 4 ICS.</p>

<p>Please help me!</p>

<p>source: <a href="http://www.how-android.com/thread-galaxy-s2-mapservicesamsung-error-after-ics-upgrade" rel="nofollow">http://www.how-android.com/thread-galaxy-s2-mapservicesamsung-error-after-ics-upgrade</a></p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/hardware-and-software/tablets-and-mobile-devices/98">Tablets and Mobile Devices</category>
			<dc:creator>anna_mariya</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/hardware-and-software/tablets-and-mobile-devices/threads/455097/galaxy-s2-mapservicesamsung-error-after-ics-upgrade-</guid>
		</item>
				<item>
			<title>Javax USB problem</title>
			<link>http://www.daniweb.com/software-development/java/threads/455096/javax-usb-problem</link>
			<pubDate>Wed, 22 May 2013 10:07:44 +0000</pubDate>
			<description>I am trying to use java to detect when a USB is inserted and to read from it. I am currently using javax.usb to try to accomplish this however I get this error (line 11) when running my program javax.usb.UsbException: The property javax.usb.services is not defined as the implementation class ...</description>
			<content:encoded><![CDATA[ <p>I am trying to use java to detect when a USB is inserted and to read from it. I am currently using javax.usb to try to accomplish this however I get this error (line 11) when running my program</p>

<pre><code class="language-java">javax.usb.UsbException: The property javax.usb.services is not defined as the implementation class of UsbServices
</code></pre>

<p>I have inserted the javax.usb.properties file in the top directory of the jar (which seemed to solve my previous error)</p>

<p>Here is my code</p>

<pre><code class="language-java">import java.util.Iterator;
import java.util.List;

import javax.usb.*;

public class Main {


    public static void main(String[] args) {
        try {

            UsbServices serv = UsbHostManager.getUsbServices();
            UsbHub root = serv.getRootUsbHub();

            List devices = root.getAttachedUsbDevices();
            Iterator itr = devices.iterator();
            while (itr.hasNext()){
                UsbDevice dev = (UsbDevice) itr.next();
                if (dev.isUsbHub()){
                    System.out.println("Is USB Hub");
                }
            }

        } catch (SecurityException e) {
            // TODO Auto-generated catch block
            e.printStackTrace();
        } catch (UsbException e) {
            // TODO Auto-generated catch block
            e.printStackTrace();
        }


    }

}
</code></pre>

<p>Thank you for your help.</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/software-development/java/9">Java</category>
			<dc:creator>sirlink99</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/software-development/java/threads/455096/javax-usb-problem</guid>
		</item>
				<item>
			<title>Can I install XP Professional &amp; Windows 7 together in my PC</title>
			<link>http://www.daniweb.com/hardware-and-software/microsoft-windows/windows-vista-and-windows-7-8/threads/455095/can-i-install-xp-professional-windows-7-together-in-my-pc</link>
			<pubDate>Wed, 22 May 2013 09:46:55 +0000</pubDate>
			<description>I want to do Medical transcription practice at home but it can be worked only in Windows XP Professional. I have installed Windows 7 earlier. Now I have uninstall Windows 7 and installed XP Professional. But I want to install Windows 7 also for my other works. Can I install ...</description>
			<content:encoded><![CDATA[ <p>I want to do Medical transcription practice at home but it can be worked only in Windows XP Professional.  I have installed Windows 7 earlier.  Now I have uninstall Windows 7 and installed XP Professional.  But I want to install Windows 7 also for my other works.  Can I install both Windows XP Professional &amp; Windows 7 together.  If so, how is it possible?  Please suggest me.  I feel I am missing Windows 7.</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/hardware-and-software/microsoft-windows/windows-vista-and-windows-7-8/38">Windows Vista and Windows 7 / 8</category>
			<dc:creator>sangee1311</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/hardware-and-software/microsoft-windows/windows-vista-and-windows-7-8/threads/455095/can-i-install-xp-professional-windows-7-together-in-my-pc</guid>
		</item>
				<item>
			<title>How to redirect to another jsp page based upon option selected.</title>
			<link>http://www.daniweb.com/web-development/jsp/threads/455094/how-to-redirect-to-another-jsp-page-based-upon-option-selected</link>
			<pubDate>Wed, 22 May 2013 09:38:56 +0000</pubDate>
			<description> I have the following field in a jsp page.. &lt;select size=&quot;1&quot; name=&quot;typ&quot;&gt; &lt;option value=&quot;C&quot;&gt;Coffe&lt;/option&gt; &lt;option value=&quot;T&quot;&gt;Tea&lt;/option&gt; &amp;nbsp; &lt;/select&gt; Now when the user selects Coffeand and clicks submit, I want the page to go to Coffe.jsp and when Tea is selected , i want it to go to Tea.jsp I tried ...</description>
			<content:encoded><![CDATA[ <p>I have the following field in a jsp page..</p>

<pre><code>   &lt;select size="1" name="typ"&gt;
                                    &lt;option value="C"&gt;Coffe&lt;/option&gt;
                                    &lt;option value="T"&gt;Tea&lt;/option&gt;
                                    &amp;nbsp;
                                &lt;/select&gt;
</code></pre>

<p>Now when the user selects Coffeand and clicks submit, I want the page to go to Coffe.jsp<br />
 and when Tea is selected , i want it to go to Tea.jsp</p>

<p>I tried using the following jquery code but it is not working...</p>

<pre><code> jQuery(document).ready(function() {
                jQuery("#typ").change(function() {
                    if(this.options[this.selectedIndex].value == "C") {
                        window.location = "/Coffee.jsp";
                    }
                });
</code></pre>

<p>I am a newbie in jquery script and jsp...</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/web-development/jsp/24">JSP</category>
			<dc:creator>razor2890</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/web-development/jsp/threads/455094/how-to-redirect-to-another-jsp-page-based-upon-option-selected</guid>
		</item>
				<item>
			<title>Multi Master to one slave</title>
			<link>http://www.daniweb.com/web-development/databases/mysql/threads/455091/multi-master-to-one-slave</link>
			<pubDate>Wed, 22 May 2013 09:02:00 +0000</pubDate>
			<description>Hi buddies how are you, now am using replication for mysql database from one server to other Master-slave replication, using this article https://www.digitalocean.com/community/articles/how-to-set-up-master-slave-replication-in-mysql but this not satisfied my needs, I have multiple server and all their databased replication to single slave server to be more accurate, I have servers **A**, ...</description>
			<content:encoded><![CDATA[ <p>Hi buddies how are you, now am using replication for mysql database from one server to other<br />
Master-slave replication, using this article <a href="https://www.digitalocean.com/community/articles/how-to-set-up-master-slave-replication-in-mysql" rel="nofollow">https://www.digitalocean.com/community/articles/how-to-set-up-master-slave-replication-in-mysql</a></p>

<p>but this not satisfied my needs, I have multiple server and all their databased replication to single slave server</p>

<p>to be more accurate, I have servers <strong>A</strong>, <strong>B</strong> ,<strong>C</strong>  I want to replicate their databses to server <strong>D</strong><br />
from which I learned the command to select the master server is by:</p>

<p><code>CHANGE MASTER TO MASTER_HOST='12.34.56.789',MASTER_USER='slave_user', MASTER_PASSWORD='password', MASTER_LOG_FILE='mysql-bin.000001', MASTER_LOG_POS=  107;</code></p>

<p>how it possible to select multiple masters ?<br />
am thinking of create a series of master slave replications, from <strong>A</strong> to <strong>B</strong> to <strong>D</strong> / <strong>C</strong> to <strong>B</strong> to <strong>D</strong> But I think I will get lost :D, hope i get the answers from you :(</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/web-development/databases/mysql/126">MySQL</category>
			<dc:creator>OsaMasw</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/web-development/databases/mysql/threads/455091/multi-master-to-one-slave</guid>
		</item>
				<item>
			<title>builder pattern question</title>
			<link>http://www.daniweb.com/software-development/java/threads/455090/builder-pattern-question</link>
			<pubDate>Wed, 22 May 2013 08:36:07 +0000</pubDate>
			<description>Hey there, I have a question regarding the builder pattern that I need someone with more experience to clarify for me. I have this User class that has an inner, public static Builder class that has the same fields as User as well as the corresponding setter methods. Now, the ...</description>
			<content:encoded><![CDATA[ <p>Hey there, I have a question regarding the builder pattern that I need someone with more experience to clarify for me.</p>

<p>I have this User class that has an inner, public static Builder class that has the same fields as User as well as the corresponding setter methods. Now, the setter methods inside the Builder class return this (the builder instance), and after everything is set, the instance of the builder is passed to Builder.build(this) method that returns a User instance with the fields.</p>

<p>My question is that I can make User setter methods to return this (User object) and render the inner Builder class unnecessary. However, since it is there, I assume there might be some reason why it is so. Anybody any suggestion as to why is one way better than the other?</p>

<p>Thanks in advance.</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/software-development/java/9">Java</category>
			<dc:creator>bibiki</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/software-development/java/threads/455090/builder-pattern-question</guid>
		</item>
				<item>
			<title>Custom validation for update </title>
			<link>http://www.daniweb.com/web-development/aspnet/threads/455089/custom-validation-for-update-</link>
			<pubDate>Wed, 22 May 2013 08:30:31 +0000</pubDate>
			<description>I have a gridview that stores information about items - a number and a name, I have a custom validator set agains t to check the number doesn't already exist in the database to prevent duplication. protected void CustomValTBCodeServerValidate(object source, ServerValidateEventArgs args) { TextBox newCode = (TextBox)fvCode.FindControl(&quot;TbCode&quot;); String XCode = ...</description>
			<content:encoded><![CDATA[ <p>I have a gridview that stores information about items - a number and a name, I have a custom validator set agains t to check the number doesn't already exist in the database to prevent duplication.</p>

<pre><code>   protected void CustomValTBCodeServerValidate(object source, ServerValidateEventArgs args)
        {
            TextBox newCode = (TextBox)fvCode.FindControl("TbCode");

            String XCode = newCode.Text;
            X a = (X)XManager.XGetByCode(XCode);
            String existCode = a.XCode;



            args.IsValid = (XCode != existCode);

            if (args.IsValid == true)
            {
                pnlSuccess.Visible = true;
            }

            else
            {
                pnlFail.Visible = true;
            }
        }
</code></pre>

<p>However this is preventing me from updating the record as the number already exists, I need it to allow the row i'm updating to update with the code and text if the current code only exists once.</p>

<p>Anyone any ideas?</p>

<p>Thanks</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/web-development/aspnet/18">ASP.NET</category>
			<dc:creator>coder91</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/web-development/aspnet/threads/455089/custom-validation-for-update-</guid>
		</item>
				<item>
			<title>Connection String for a DataBase.accdb file?</title>
			<link>http://www.daniweb.com/software-development/csharp/threads/455088/connection-string-for-a-database.accdb-file</link>
			<pubDate>Wed, 22 May 2013 08:20:52 +0000</pubDate>
			<description>I added a DataBase.accdb file into a project (VS 2010) then created a DataSet. but now I've a small problem: I want to have the connection string in the app.config file, to allow customer to edit it. I go to the app.config file and find no connection string created inside. ...</description>
			<content:encoded><![CDATA[ <p>I added a  DataBase.accdb file into a project (VS 2010) then created a DataSet. but now I've a small problem:</p>

<p>I want to have the connection string in the app.config file, to allow customer to edit it. I go to the app.config file and find no connection string created inside. how can i make dataset create connection string automaticaly inside app.config file then always use it.</p>

<p>why connection string for *.accdb donot have db password and user name in it auto???</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/software-development/csharp/61">C#</category>
			<dc:creator>IT_Techno</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/software-development/csharp/threads/455088/connection-string-for-a-database.accdb-file</guid>
		</item>
				<item>
			<title>How to work with *.cpp and VB</title>
			<link>http://www.daniweb.com/software-development/vbnet/threads/455087/how-to-work-with-.cpp-and-vb</link>
			<pubDate>Wed, 22 May 2013 08:18:40 +0000</pubDate>
			<description>Hi everyone! This is my very first post. I hope that some can help me. I'm totally newbie to VB but i need to make a executable file to do this: Open a given *.cpp file, and for every line inside this file check all the words containing only uppercase ...</description>
			<content:encoded><![CDATA[ <p>Hi everyone! This is my very first post. I hope that some can help me.<br />
I'm totally newbie to VB but i need to make a executable file to do this:<br />
Open a given <em>.cpp file, and for every line inside this file check all the words containing only uppercase single words or upper case words seperated by "<strong>_</strong>" (</em>This is the standard to be accepted as a properly declared constant inside that .cpp file*), finally the code must display a message saying how many constants has been properly declared and how many wasn't.</p>

<p>Let's suppose that this is the code:</p>

<pre><code class="language-vb">#define WEEK_DAYS 7
#define PI 3.141592
#define COUNt 1000
state = EXITO;
i = 0;
  while ((string[i] != NULL &amp;&amp; (state == SUCCESS)) 
  {
    transmitCar(string[i], &amp;state);
  }
</code></pre>

<p>The program should say:<br />
3 variables found!<br />
2 Variables passed the test<br />
1 variable failed the test.<br />
Score is 0.66</p>

<p>For now, i can open the .cpp file and i can display the code inside on a window, nothing else. My idea is trying to seperate every word or character with <code>line.Split</code>and store it using an array, and after that use a for sentence to go over the array, find every word with upper case characters and delete the "<strong>_</strong>" and then count all the word. But that procedure only has to be done if before the word there is a #define.</p>

<p>Thanks in advance. And sorry for my english.<br />
P.D The code doesn't need to be pretty, stable or optimized, but if it works, it's great.</p>

<p>This is my code, i know it's awful.</p>

<pre><code class="language-vb">Imports System.IO
Imports System.Text
Public Class Código

    Private Property fileList As ObjectModel.ReadOnlyCollection(Of String)

    Private Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click
        Dim myStream As Stream = Nothing
        Dim openFileDialog1 As New OpenFileDialog()
        Dim i As Integer = 0
        Dim line As String
        openFileDialog1.InitialDirectory = "c:\"
        openFileDialog1.Filter = "Archivos de C++ (*.CPP)|*.CPP|Todos los archivos (*.*)|*.*"
        openFileDialog1.FilterIndex = 2
        openFileDialog1.RestoreDirectory = True
        If openFileDialog1.ShowDialog() = System.Windows.Forms.DialogResult.OK Then
            Try
                myStream = openFileDialog1.OpenFile()
                If (myStream IsNot Nothing) Then

                    'Algoritmo para evaluar el codigo: 

                    Dim fileReader As String
                    fileReader = My.Computer.FileSystem.ReadAllText("C:\Codigo.cpp", _
                    System.Text.Encoding.ASCII)
                    MsgBox(fileReader)
                    For Each line In File.ReadAllLines("C:\Codigo.cpp")

                        ' Split line on comma
                        Dim parts As String() = line.Split(New Char() {" "c})

                        ' Loop over each string received
                        Dim part As String
                        For Each part In parts
                            ' Display to Console
                            Console.WriteLine("{0}:{1}", i, part)
                        Next
                        i += 1
                    Next

                End If
            Catch Ex As Exception
                MessageBox.Show("No se puede leer el archivo." &amp; Ex.Message)
            Finally
                'Check this again, since we need to make sure we didn't throw an exception on open. 
                If (myStream IsNot Nothing) Then
                    myStream.Close()
                End If
            End Try
        End If
    End Sub
End Class
</code></pre>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/software-development/vbnet/58">VB.NET</category>
			<dc:creator>LuisAZC</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/software-development/vbnet/threads/455087/how-to-work-with-.cpp-and-vb</guid>
		</item>
				<item>
			<title>Hide panel in another form</title>
			<link>http://www.daniweb.com/software-development/csharp/threads/455086/hide-panel-in-another-form</link>
			<pubDate>Wed, 22 May 2013 08:03:55 +0000</pubDate>
			<description>I would like to hide another panel from another form when I click From frmMain: frmSearch Search = new frmSearch(); Search.Show(); From frmSearch: I would like to view Panel2 and not Panel1 Thank you!</description>
			<content:encoded><![CDATA[ <p>I would like to hide another panel from another form when I click</p>

<p>From frmMain:</p>

<pre><code class="language-cs">frmSearch Search = new frmSearch();
Search.Show();
</code></pre>

<p>From frmSearch:<br />
I would like to view Panel2 and not Panel1</p>

<p>Thank you!</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/software-development/csharp/61">C#</category>
			<dc:creator>jaejoong</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/software-development/csharp/threads/455086/hide-panel-in-another-form</guid>
		</item>
				<item>
			<title>Java</title>
			<link>http://www.daniweb.com/software-development/java/threads/455085/java</link>
			<pubDate>Wed, 22 May 2013 07:55:41 +0000</pubDate>
			<description>Hello Everyone... I am new to the Java and want to learn java from the beginning... Please suggest me some good books and references to learn java efficiently...</description>
			<content:encoded><![CDATA[ <p>Hello Everyone...<br />
I am new to the Java and want to learn java from the beginning...<br />
Please suggest me some good books and references to learn java efficiently...</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/software-development/java/9">Java</category>
			<dc:creator>jacksonbird03</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/software-development/java/threads/455085/java</guid>
		</item>
				<item>
			<title>grams conversion to tola masha and ratti</title>
			<link>http://www.daniweb.com/software-development/vbnet/threads/455083/grams-conversion-to-tola-masha-and-ratti</link>
			<pubDate>Wed, 22 May 2013 07:35:50 +0000</pubDate>
			<description>i am making a module in vb.net which will convert number of grams to number of tola masha and ratti respectively. 1 tola = 12 masha 1 masha= 8 ratti while 1 tola = 12.5 grams i can make number of tolas by number of grams \ 12.5 but can ...</description>
			<content:encoded><![CDATA[ <p>i am making a module in vb.net which will convert number of grams to number of tola masha and ratti respectively.<br />
1 tola = 12 masha<br />
1 masha= 8 ratti<br />
while<br />
1 tola = 12.5 grams<br />
i can make number of tolas by number of grams \ 12.5<br />
but can go any further.</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/software-development/vbnet/58">VB.NET</category>
			<dc:creator>Affable zaki</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/software-development/vbnet/threads/455083/grams-conversion-to-tola-masha-and-ratti</guid>
		</item>
				<item>
			<title>Having trouble with rename()</title>
			<link>http://www.daniweb.com/web-development/php/threads/455082/having-trouble-with-rename</link>
			<pubDate>Wed, 22 May 2013 07:30:49 +0000</pubDate>
			<description>Hi everyone. It's been a while since I've needed help with a PHP problem. Hopefully someone here knows what I'm doing wrong because I can't see it. I am trying to use rename() to rename an image file which is in a subdirectory of a subdirectory the script is running ...</description>
			<content:encoded><![CDATA[ <p>Hi everyone. It's been a while since I've needed help with a PHP problem. Hopefully someone here knows what I'm doing wrong because I can't see it.</p>

<p>I am trying to use rename() to rename an image file which is in a subdirectory of a subdirectory the script is running in. The script is running in "/folder" and the images are held in "/folder/images/general"</p>

<p>The script I currently have is:</p>

<pre><code>$old = "./images/general/item2.jpg";
$new = "./images/general/item44.jpg";

if(file_exists($old))
{
    rename($old, $new);
    echo "yes";
}
else
{
    echo "no";
}
</code></pre>

<p>The if statement is finding the file as my browser is outputting "yes" however the file is not being renamed. The permissions of the image file are 644 which as far as I am aware, is all it needs to be but I have tried with the permissions set to 666 and even 777. Have I missed something increadibly obvious?</p>

<p>I need the script to be able to rename the image as it's uploaded (was going to have it uploaded, then renamed unless there's a more efficient way?) and to rename files which already exist.</p>

<p>Unfortunately, error logging is disabled on the server this is hosted on and I don't have the necessary access to enable it. Is there maybe something I can put in die() to output the PHP error to the browser just like <code>die(mysql_error());</code> would output the MySQL error?</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/web-development/php/17">PHP</category>
			<dc:creator>Borzoi</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/web-development/php/threads/455082/having-trouble-with-rename</guid>
		</item>
				<item>
			<title>Erk</title>
			<link>http://www.daniweb.com/community-center/geeks-lounge/threads/455081/erk</link>
			<pubDate>Wed, 22 May 2013 06:47:02 +0000</pubDate>
			<description>Got into office at 6.30am yesterday (hour later than usual) and was going back home by 8am. Ended up back in bed at 10am, woke again at 4pm. Back in bed at 8pm, slept through until 6am this morning. Wow! Really strange bug, high temperature and very weak (had to ...</description>
			<content:encoded><![CDATA[ <p>Got into office at 6.30am yesterday (hour later than usual) and was going back home by 8am. Ended up back in bed at 10am, woke again at 4pm. Back in bed at 8pm, slept through until 6am this morning. Wow! Really strange bug, high temperature and very weak (had to <strong>crawl</strong> up the stairs to bed FFS!) plus no appetite (one slice of toast all day) but feel fine today. Susie also had same thing yesterday, with the addition of vomiting throughout - so I think I got off lightly.</p>

<p>I am going to get over it by spending the morning in the office catching up on the work I coudln't do yesterday, then four hours in the chair this afternoon having both sides of my neck, and the bottom of the back of my head, tattooed this afternoon :)</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/community-center/geeks-lounge/6">Geeks' Lounge</category>
			<dc:creator>happygeek</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/community-center/geeks-lounge/threads/455081/erk</guid>
		</item>
				<item>
			<title>Address bar missing in Windows Explorer</title>
			<link>http://www.daniweb.com/hardware-and-software/microsoft-windows/windows-nt-2000-xp/threads/455080/address-bar-missing-in-windows-explorer</link>
			<pubDate>Wed, 22 May 2013 06:33:03 +0000</pubDate>
			<description>I found quiet old post unsolved and find similar problem. Here is the solution. Start | Run | Type or paste: REGSVR32 /i BROWSEUI.DLL Click OK | Reboot This may work for IE also.</description>
			<content:encoded><![CDATA[ <p>I found quiet old post unsolved and find similar problem.<br />
Here is the solution.<br />
Start | Run | Type or paste: REGSVR32 /i BROWSEUI.DLL<br />
Click OK | Reboot</p>

<p>This may work for IE also.</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/hardware-and-software/microsoft-windows/windows-nt-2000-xp/10">Windows NT / 2000 / XP</category>
			<dc:creator>Prasad Thale</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/hardware-and-software/microsoft-windows/windows-nt-2000-xp/threads/455080/address-bar-missing-in-windows-explorer</guid>
		</item>
				<item>
			<title>Run Python script in different environments</title>
			<link>http://www.daniweb.com/software-development/python/threads/455079/run-python-script-in-different-environments</link>
			<pubDate>Wed, 22 May 2013 06:31:53 +0000</pubDate>
			<description>Hi I am trying to run a python script which has this code snippet: process = subprocess.Popen('./start_ws.pl') process.wait() os.system('make') The perl script started changes environmental variables and enters into new subshell. After entering into new subshell, the commands below script os.system('make') goes unnoticed.They get executed only if i exit from ...</description>
			<content:encoded><![CDATA[ <p>Hi I am trying to run a python script which has this code snippet:</p>

<pre><code class="language-py">process = subprocess.Popen('./start_ws.pl')
process.wait()
os.system('make')
</code></pre>

<p>The perl script started changes environmental variables and<br />
enters into new subshell.<br />
After entering into new subshell, the commands below script</p>

<pre><code class="language-py">os.system('make')
</code></pre>

<p>goes unnoticed.They get executed only if i exit from subshell(created by pl script).<br />
The system command 'make' is executable only in new subshell.</p>

<p>I tried like,</p>

<pre><code class="language-py">pid = os.fork()

if pid &gt; 0:
  os.wait()
  os.system('make clean')

else:
  os.system('./start_ws.pl')
</code></pre>

<p>Even this doesnt work.</p>

<p>Kindly help me to run 'make' command in same env created by 'start_ws.pl' perl script.</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/software-development/python/114">Python</category>
			<dc:creator>Meena Yegappan</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/software-development/python/threads/455079/run-python-script-in-different-environments</guid>
		</item>
				<item>
			<title>Networking Basics</title>
			<link>http://www.daniweb.com/hardware-and-software/networking/threads/455078/networking-basics</link>
			<pubDate>Wed, 22 May 2013 06:31:28 +0000</pubDate>
			<description>How long is an Ipv6 adress?</description>
			<content:encoded><![CDATA[ <p>How long is an Ipv6 adress?</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/hardware-and-software/networking/13">Networking</category>
			<dc:creator>nicolestar</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/hardware-and-software/networking/threads/455078/networking-basics</guid>
		</item>
				<item>
			<title>Google calender issue </title>
			<link>http://www.daniweb.com/web-development/php/threads/455077/google-calender-issue-</link>
			<pubDate>Wed, 22 May 2013 06:25:04 +0000</pubDate>
			<description>Hello there, Does anyone know about following google calender issue: I had code for google calender invitation. But due to some reson I add patch over there which fetches some extra information and merge in the body of that mail. But what I found is : when I add patch ...</description>
			<content:encoded><![CDATA[ <p>Hello there,<br />
Does anyone know about following google calender issue:<br />
I had code for google calender invitation.<br />
But due to some reson I add patch over there which fetches some extra information and merge in the body of that mail.<br />
But what I found is : when I add patch there, It takes only some starting part of information.<br />
Final conclusion is it takes particular length of data in calender.<br />
(If you say how I came to this decission, then here is my answer: I tried to remove previous part of my message then it added next few lines of added patch. I again removed some part of body message, it again take some part of message!!! )</p>

<p>Is this known issue or am wrong somewhere?<br />
Help me out please. This issue is wasting my time.<br />
Please let me know if am not clear in this question.</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/web-development/php/17">PHP</category>
			<dc:creator>Priti_P</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/web-development/php/threads/455077/google-calender-issue-</guid>
		</item>
				<item>
			<title>hard drive space gone</title>
			<link>http://www.daniweb.com/hardware-and-software/linux-and-unix/threads/455076/hard-drive-space-gone</link>
			<pubDate>Wed, 22 May 2013 06:09:11 +0000</pubDate>
			<description>hello I don't get where my linux space is gone. when i run df -h, it shows used 15 GB of total 20 GB when I run ncdu program, to find what takes, I do sudo ncdu in my root directory. And I see sorted by size directories: 4.7GB home ...</description>
			<content:encoded><![CDATA[ <p>hello</p>

<p>I don't get where my linux space is gone.</p>

<p>when i run df -h, it shows used 15 GB of total 20 GB</p>

<p>when I run ncdu program, to find what takes, I do sudo ncdu in my root directory. And I see sorted by size directories:</p>

<p>4.7GB home<br />
4.5GB var<br />
1.3 GB usr</p>

<p>and later is 19 MB lib and so on</p>

<p>so adding up - the space is 4.7+4.5+1.3 = 10.5. OK plus those small directoreis lets roudn to 11 GB used. So where are my 4 GB then?</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/hardware-and-software/linux-and-unix/12">Linux and Unix</category>
			<dc:creator>SPeed_FANat1c</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/hardware-and-software/linux-and-unix/threads/455076/hard-drive-space-gone</guid>
		</item>
				<item>
			<title>how to I check for existing username without using mysql in php?</title>
			<link>http://www.daniweb.com/web-development/php/threads/455075/how-to-i-check-for-existing-username-without-using-mysql-in-php</link>
			<pubDate>Wed, 22 May 2013 05:19:25 +0000</pubDate>
			<description>How to I check for existing username without using mysql in php? I tried something like this but it isnt working. Please help. Thanks. Strictly no SQL... $name=$nme; $name = file(&quot;datatext/users.txt&quot;); $ic=file(&quot;datatext/users.txt&quot;); if (this.$nme== $name) { echo &quot;this user exits, please log in&quot;; }</description>
			<content:encoded><![CDATA[ <p>How to I check for existing username without using mysql in php?<br />
I tried something like this but it isnt working. Please help. Thanks. Strictly no SQL...</p>

<pre><code>     $name=$nme;
        $name = file("datatext/users.txt");
        $ic=file("datatext/users.txt");
        if (this.$nme== $name)
        {
        echo "this user exits, please log in";
        }
</code></pre>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/web-development/php/17">PHP</category>
			<dc:creator>xianamersu</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/web-development/php/threads/455075/how-to-i-check-for-existing-username-without-using-mysql-in-php</guid>
		</item>
				<item>
			<title>Anti-tobacco movement in Nazi Germany</title>
			<link>http://www.daniweb.com/community-center/geeks-lounge/threads/455074/anti-tobacco-movement-in-nazi-germany</link>
			<pubDate>Wed, 22 May 2013 04:32:35 +0000</pubDate>
			<description>http://en.wikipedia.org/wiki/Anti-tobacco_movement_in_Nazi_Germany &gt; Adolf Hitler was a heavy smoker in his early life — he used to smoke 25 to 40 cigarettes daily — but gave up the habit, concluding that it was a waste of money. In later years, Hitler viewed smoking as &quot;decadent&quot; and &quot;the wrath of the Red ...</description>
			<content:encoded><![CDATA[ <p><a href="http://en.wikipedia.org/wiki/Anti-tobacco_movement_in_Nazi_Germany" rel="nofollow">http://en.wikipedia.org/wiki/Anti-tobacco_movement_in_Nazi_Germany</a></p>

<blockquote>
  <p>Adolf Hitler was a heavy smoker in his early life — he used to smoke 25 to 40 cigarettes daily — but gave up the habit, concluding that it was a waste of money. In later years, Hitler viewed smoking as "decadent" and "the wrath of the Red Man against the White Man, vengeance for having been given hard liquor", lamenting that "so many excellent men have been lost to tobacco poisoning". He was unhappy because both Eva Braun and Martin Bormann were smokers and was concerned over Hermann Göring's continued smoking in public places. He was angered when a statue portraying a cigar-smoking Göring was commissioned. Hitler is often considered to be the first national leader to advocate nonsmoking, although James VI and I of Great Britain has a better claim to that title by three hundred years.</p>
</blockquote>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/community-center/geeks-lounge/6">Geeks' Lounge</category>
			<dc:creator>Xantipius</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/community-center/geeks-lounge/threads/455074/anti-tobacco-movement-in-nazi-germany</guid>
		</item>
				<item>
			<title>stuck again - method to change text box value</title>
			<link>http://www.daniweb.com/software-development/csharp/threads/455073/stuck-again-method-to-change-text-box-value</link>
			<pubDate>Wed, 22 May 2013 02:04:11 +0000</pubDate>
			<description>i seem to get stuck a lot but... I want to have a method displayData() that when called will change richtTextBox.Text to a string value I have. But I don't know how to access the richt text box from within my method. I tried changing it to public using its ...</description>
			<content:encoded><![CDATA[ <p>i seem to get stuck a lot but... I want to have a method displayData() that when called will change richtTextBox.Text to a string value I have. But I don't know how to access the richt text box from within my method. I tried changing it to public using its properties but that didn't work . And Form3.richTextBox doesn't work either. I have a feeling this isn't actually possible, so if not what should I do to work around this problem?</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/software-development/csharp/61">C#</category>
			<dc:creator>pwolf</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/software-development/csharp/threads/455073/stuck-again-method-to-change-text-box-value</guid>
		</item>
				<item>
			<title>Install Tiny7 onto a computer without an OS!!!</title>
			<link>http://www.daniweb.com/hardware-and-software/threads/455072/install-tiny7-onto-a-computer-without-an-os</link>
			<pubDate>Wed, 22 May 2013 01:40:48 +0000</pubDate>
			<description>**REALLY URGENT: Please help if you can!?!?!?!?!? So I decided to install Tiny 7 by eXPerience one day. I have a russian Roverbook Voyager CT5 W which is pretty old [2002-2004]. It has a 1.80 Ghz intel pentium 4 processer, 256 megabytes of ram, and a 27 gigabyte hard drive. ...</description>
			<content:encoded><![CDATA[ <p>**REALLY URGENT: Please help if you can!?!?!?!?!?<br />
So I decided to install Tiny 7 by eXPerience one day. I have a russian Roverbook Voyager CT5 W which is pretty old [2002-2004]. It has a 1.80 Ghz intel pentium 4 processer, 256 megabytes of ram, and a 27 gigabyte hard drive. As I was going to install it, I heard that you need a fresh partition on your hard drive to install Tiny 7. So I completely misunderstood that and thought that it ment you needed a fresh hard drive without any files on it [basically a computer without anything but bios]. I used some program that you boot at startup to completely wipe all the files off of the hard drive and completely screwed up. I later found that Tiny 7 won't install without bootcamp and without creating a partition. Which of course you need an os to perform that! So now I am left with a computer that is basically useless. Not only that, but it is my mom's very old laptop. Not to worry about files, I backed them up. Just that my parents might get pretty pissed that the laptop won't work [we have a family desktop so we basically forgot about this laptop, but I bet my parents will find out]. So maybe someone can tell me where i can get a pirated xp or something and how to boot it from usb, or maybe they have completely different advice for me. Maybe you can create a partition without an os????? Well now that you know my situation any and every response will be appreciated!!! Thanx :)</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/hardware-and-software/1">Hardware and Software</category>
			<dc:creator>temir</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/hardware-and-software/threads/455072/install-tiny7-onto-a-computer-without-an-os</guid>
		</item>
				<item>
			<title>unreachable code detected?</title>
			<link>http://www.daniweb.com/software-development/csharp/threads/455071/unreachable-code-detected</link>
			<pubDate>Wed, 22 May 2013 01:08:55 +0000</pubDate>
			<description>whats wrong with this code? It keeps giving me an &quot;unreachable code detected &quot; exception public static int search(string Registration) { // this method will search for registration, if found it will return the index value , else it will return max value + 1 for (int x = 0; ...</description>
			<content:encoded><![CDATA[ <p>whats wrong with this code? It keeps giving me an "unreachable code detected " exception</p>

<pre><code class="language-cs">public static int search(string Registration)
        {
            // this method will search for registration, if found it will return the index value , else it will return max value + 1          

            for (int x = 0; x &lt; numOfRowsCars; x++)
            {
                reg = ds1.Tables["tblCars"].Rows[x][2].ToString();
                MessageBox.Show(reg);
                if (Registration == reg)
                {
                    // Then return the index of the registration number 
                    return x;
                }
                else
                {
                    // Then return the max index + 1
                    return numOfRowsCars;
                }
            }                              
        }
</code></pre>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/software-development/csharp/61">C#</category>
			<dc:creator>pwolf</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/software-development/csharp/threads/455071/unreachable-code-detected</guid>
		</item>
				<item>
			<title>Suggestion: There should be a PHP forum</title>
			<link>http://www.daniweb.com/community-center/daniweb-community-feedback/threads/455070/suggestion-there-should-be-a-php-forum</link>
			<pubDate>Wed, 22 May 2013 00:13:40 +0000</pubDate>
			<description>I've noticed there isn't a php forum in the software development section. It would be cool if one could get created.</description>
			<content:encoded><![CDATA[ <p>I've noticed there isn't a php forum in the software development section. It would be cool if one could get created.</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/community-center/daniweb-community-feedback/26">DaniWeb Community Feedback</category>
			<dc:creator>joshfizzle</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/community-center/daniweb-community-feedback/threads/455070/suggestion-there-should-be-a-php-forum</guid>
		</item>
				<item>
			<title>Up votes</title>
			<link>http://www.daniweb.com/community-center/daniweb-community-feedback/threads/455069/up-votes</link>
			<pubDate>Tue, 21 May 2013 22:05:42 +0000</pubDate>
			<description>I recently intended to upvote with a comment but accudently upvoted without comment. I then pressed the uparrow again to erase my previous upvote so that I could do it again. I added the comment, pressed uparrow and the comment was accepted, however after I refreshed the page I noticed ...</description>
			<content:encoded><![CDATA[ <p>I recently intended to upvote with a comment but accudently upvoted without comment.  I then pressed the uparrow again to erase my previous upvote so that I could do it again.  I added the comment, pressed uparrow and the comment was accepted, however after I refreshed the page I noticed that the member's rep was not changed.</p>

<p>Once an upvote without comment is made is it not possible to add comment so that the member's rep is increased?</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/community-center/daniweb-community-feedback/26">DaniWeb Community Feedback</category>
			<dc:creator>Ancient Dragon</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/community-center/daniweb-community-feedback/threads/455069/up-votes</guid>
		</item>
				<item>
			<title>What does the while-statement mean and do?</title>
			<link>http://www.daniweb.com/software-development/cpp/threads/455068/what-does-the-while-statement-mean-and-do</link>
			<pubDate>Tue, 21 May 2013 20:41:17 +0000</pubDate>
			<description>Hi everyone I'm studying the part about while-statement but I don't understand the explanation in the book really well and the example doesn't work for me so I can't see it with my own eyes how it works. Can someone explain what the while-statement means and does? Also can you ...</description>
			<content:encoded><![CDATA[ <p>Hi everyone</p>

<p>I'm studying the part about while-statement but I don't understand the explanation in the book really well and the example doesn't work for me so I can't see it with my own eyes how it works.<br />
Can someone explain what the while-statement means and does? Also can you give an example that might work?</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/software-development/cpp/8">C++</category>
			<dc:creator>Kareem Klas</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/software-development/cpp/threads/455068/what-does-the-while-statement-mean-and-do</guid>
		</item>
				<item>
			<title>Redirecting problem in the PHP code, Can you help</title>
			<link>http://www.daniweb.com/web-development/php/threads/455067/redirecting-problem-in-the-php-code-can-you-help</link>
			<pubDate>Tue, 21 May 2013 20:26:03 +0000</pubDate>
			<description>Hy All Im here again to ask for you help. I still in the begining to launch the site, and i found a major error. The theory is the following. I planning to start a Pay per download site, which mean the members upload a file and when somebody want ...</description>
			<content:encoded><![CDATA[ <p>Hy All</p>

<p>Im here again to ask for you help. I still in the begining to launch the site, and i found a major error. The theory is the following. I planning to start a Pay per download site, which mean the members upload a file and when somebody want to download it, they have to fill a short survey. After survey done, both me and them get money. The problem is i test the script, and when i open the donwload link  <a href="http://www.filemonster.org/download.php?id=11" rel="nofollow">http://www.filemonster.org/download.php?id=11</a> the page load, then immediately redirect and i get a following error "Stop trying to download without completing a survey." which is an anti cheat message. Its 100% wrong because its appears all the time. i paste here the code, do you know why its appear straight after the page load? Its just appear for me on the Firefox.</p>

<pre><code>&lt;?php 
ob_start();
session_start();
include_once('secure/core.php');
if (!isset($_GET['extra'])){    
    echo '&lt;script type="text/javascript"&gt;alert("Invalid access.");&lt;/script&gt;';
    die();
}
$path = $settings-&gt;getUploadPath();
$rand = mysql_real_escape_string($_GET['rand']);
$sql = "SELECT * FROM `conversions` WHERE `rand` = '$rand' and `converted` = '1'";
$result = mysql_query($sql);
$row = mysql_fetch_assoc($result);
$file = $row['file_id'];
if($row['converted'] == '1') {
if($row['downloaded'] == '0') {
$path = $settings-&gt;getUploadPath(); 
$sql5 = "select * from `uploads` where `id` = '$file'";
$row5 = $ado-&gt;fetch($ado-&gt;exec($sql5));
$sql6 = "UPDATE `conversions` SET `downloaded` = '1' WHERE `rand` = '$rand'";
$ado-&gt;exec($sql6);
set_time_limit(0);  

header("Pragma: public");
header("Expires: 0");
header("Cache-Control: must-revalidate, post-check=0, pre-check=0");
header("Cache-Control: public");
header("Content-Description: File Transfer");
header("Content-Type: application/force-download"); 
header("Content-Type: application/octet-stream"); 
header("Content-Type: application/download"); 
header("Content-Disposition: attachment; filename=\"".$row5['hash']."\"");
header("Content-Transfer-Encoding: binary");
header("Content-Length: ".filesize($path.$row5['hash']));
ob_end_flush(); 
@readfile($path.$row5['hash']);
exit(0); 

} else {
echo '&lt;script type="text/javascript"&gt;alert("You have already downloaded this.");&lt;/script&gt;';
}
} else {
echo '&lt;script type="text/javascript"&gt;alert("Stop trying to download without completing a survey.");&lt;/script&gt;'; 
}
?&gt;
&lt;script type="text/javascript"&gt;
$('#myModal').modal('hide');
&lt;/script&gt;
</code></pre>

<p>Please if any of you have an idea, share with me</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/web-development/php/17">PHP</category>
			<dc:creator>rolanduk</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/web-development/php/threads/455067/redirecting-problem-in-the-php-code-can-you-help</guid>
		</item>
				<item>
			<title>Questions in Graphics</title>
			<link>http://www.daniweb.com/software-development/java/threads/455066/questions-in-graphics</link>
			<pubDate>Tue, 21 May 2013 20:14:02 +0000</pubDate>
			<description>Hello. I'm quite new to Java, but I've worked on Graphics before. I have a couple of questions which are: I want to make a night sky in Java with stars which randomly switch to big stars from small and back, repeating for a set time. I also want the ...</description>
			<content:encoded><![CDATA[ <p>Hello. I'm quite new to Java, but I've worked on Graphics before.</p>

<p>I have a couple of questions which are:</p>

<p>I want to make a night sky in Java with stars which randomly switch to big stars from small and back, repeating for a set time. I also want the changes of the star size to occur with opacity, so that they appeared to glisten.</p>

<p>Another thing I want to consider is I want to create a crescent moon, which will get off of the screen in a smooth movement across the screen, replaced with a smooth movement of sun with the background color to change in order to imitate the sky during the morning’s sunrise, and stars disappear as the sun gets to the center of the screen.</p>

<p>This is what I have so far, didn’t want to make any mistakes in the beginning in order to make the path easier to go.</p>

<pre><code class="language-java">import java.awt.*;
import java.applet.*;


public class NightSky extends Applet
{

    public void paint(Graphics g)
    {

    }
}
</code></pre>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/software-development/java/9">Java</category>
			<dc:creator>Start4me</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/software-development/java/threads/455066/questions-in-graphics</guid>
		</item>
				<item>
			<title>Read string in txt file</title>
			<link>http://www.daniweb.com/software-development/cpp/threads/455065/read-string-in-txt-file</link>
			<pubDate>Tue, 21 May 2013 19:56:03 +0000</pubDate>
			<description>Hi, imnewbie to c++ programming. Im want to read some txt file that have a data write inside. The data should be &quot;WAT1235&quot; which is the license plate number. Then if the programming read this data &quot;WTA1234&quot; it will give other information like the Roadtax, Colour of the car and ...</description>
			<content:encoded><![CDATA[ <p>Hi, imnewbie to c++ programming. Im want to read some txt file that have a data write inside. The data should be "WAT1235" which is the license plate number. Then if the programming read this data "WTA1234" it will give other information like the Roadtax, Colour of the car and etc. I want to display the output should be like :</p>

<p>OUTPUT DISPLAY:</p>

<p>WTA1235<br />
Information:<br />
Roadtax:.....<br />
ModelCar:.....<br />
etc..</p>

<p>This my coding for the fisrt step read the txt file, but have some error</p>

<pre><code class="language-cpp">Inline Code Example Here
#include &lt;iostream&gt;
#include &lt;fstream&gt;
#include &lt;string&gt;

using namespace std;

void main(){

    ifstream inFile;
    inFile.open("test.txt");

    //Check for Error
    if (inFile.fail()){
        cerr &lt;&lt; "Error Opening File" &lt;&lt; endl;
        exit(1);
    }
    return 0;
}
</code></pre>

<p>Any suggestion and discuss will very helpfull.</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/software-development/cpp/8">C++</category>
			<dc:creator>sasukecold</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/software-development/cpp/threads/455065/read-string-in-txt-file</guid>
		</item>
				<item>
			<title>VC++: Catching an exception from MCIWndCreate</title>
			<link>http://www.daniweb.com/software-development/cpp/threads/455064/vc-catching-an-exception-from-mciwndcreate</link>
			<pubDate>Tue, 21 May 2013 19:26:34 +0000</pubDate>
			<description>I am using MCI controls to play media files within some software. For the most part, it works OK but sometimes things go poorly (e.g. when the media file is corrupt). How can I either put the code into a try/catch (i.e. what exception do I look for?) or how ...</description>
			<content:encoded><![CDATA[ <p>I am using MCI controls to play media files within some software.  For the most part, it works OK but sometimes things go poorly (e.g. when the media file is corrupt).</p>

<p>How can I either put the code into a try/catch (i.e. what exception do I look for?) or how can I check the file before running the code?  When it hits the MCIWndCreate... line it causes an MCI Error popup window that requires user interaction.  I would like for it stop trying to play the file (without any user interaction) and run another piece of code if the file is not playable.</p>

<pre><code class="language-cpp">HWND m_Video;
CString m_Path = "C:\\Path\\bad.mp3";
m_Video = NULL;

if(m_Video == NULL)
    m_Video = MCIWndCreate(this-&gt;GetSafeHwnd(), AfxGetInstanceHandle(), WS_CHILD | WS_VISIBLE|MCIWNDF_NOMENU,m_Path);
else
    MCIWndHome(m_Video);
int len = MCIWndGetLength(m_Video);
//code to modify len if needed is normally here
MCIWndPlayTo(m_Video, len);
</code></pre>

<p>Edit:  FWIW, it looks like the error that is being thrown is MCIERR_INVALID_FILE.</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/software-development/cpp/8">C++</category>
			<dc:creator>donaldw</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/software-development/cpp/threads/455064/vc-catching-an-exception-from-mciwndcreate</guid>
		</item>
				<item>
			<title>Running .jar on Another pc in Department</title>
			<link>http://www.daniweb.com/software-development/java/threads/455063/running-.jar-on-another-pc-in-department</link>
			<pubDate>Tue, 21 May 2013 19:18:52 +0000</pubDate>
			<description>Hi All, I created a small executable that runs an SSIS project. It works on my system but when I tried using it on a colleagues system nothing happens. I'm not overly familiar with with part of Java so any suggestions will be most appreciated.</description>
			<content:encoded><![CDATA[ <p>Hi All,</p>

<p>I created a small executable that runs an SSIS project.  It works on my system but when I tried using it on a colleagues system nothing happens.  I'm not overly familiar with with part of Java so any suggestions will be most appreciated.</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/software-development/java/9">Java</category>
			<dc:creator>Stuugie</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/software-development/java/threads/455063/running-.jar-on-another-pc-in-department</guid>
		</item>
				<item>
			<title>Rewarding Computer Science careers</title>
			<link>http://www.daniweb.com/community-center/geeks-lounge/threads/455062/rewarding-computer-science-careers</link>
			<pubDate>Tue, 21 May 2013 18:33:40 +0000</pubDate>
			<description>I'm soon to be a graduate in Computer Science with enough relevant experience to enter a good paying job as soon as I graduate. Having done software development however I'm not sure if it satisfies me on a personal level. The money's good... but the work is very repetitive and ...</description>
			<content:encoded><![CDATA[ <p>I'm soon to be a graduate in Computer Science with enough relevant experience to enter a good paying job as soon as I graduate. Having done software development however I'm not sure if it satisfies me on a personal level. The money's good... but the work is very repetitive and never feels like you're doing something that will have an impact in the world or the sciences. It will pay well but due to the hours one has to work in their life (8 hours per day) - I really don't think I can do software development for that long a period and be satisfied with my life when I look back, say when I'm 60 years old +.</p>

<p>What is a rewarding career that one can go on to from a degree like mine. Rewarding for me is something where a lot of people will benefit from something I'm producing OR it will make the world a better place OR it will give travel opportunities OR it will allow me more control over the work I'm doing OR it will provide me with the chance to do research into new interesting topics of study - any of those.</p>

<p>I've spoken to a few colleagues in the same profession and a lot of them seem to have the same view though they're hesitant to have it heard so to keep up an image but I hope some answers can be given that will be good advice to me and those with similar thoughts.</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/community-center/geeks-lounge/6">Geeks' Lounge</category>
			<dc:creator>asif49</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/community-center/geeks-lounge/threads/455062/rewarding-computer-science-careers</guid>
		</item>
				<item>
			<title>How to repeat data entered to datagrid?</title>
			<link>http://www.daniweb.com/software-development/vbnet/threads/455061/how-to-repeat-data-entered-to-datagrid</link>
			<pubDate>Tue, 21 May 2013 18:06:41 +0000</pubDate>
			<description>Hey guys! Im making a orders system, I want to add a product individually into the datagrid,for example: If I add for example 5 gl of milk it will display like this: Quantity Description 5 GL Milk But I want it to display it like this: Quantity Description 1 GL ...</description>
			<content:encoded><![CDATA[ <p>Hey guys!</p>

<p>Im making a orders system, I want to add a product individually into the datagrid,for example:</p>

<p>If I add for example 5 gl of milk it will display like this:</p>

<pre><code class="language-vb">Quantity  Description
   5       GL Milk

  But I want it to display it like this:

  Quantity  Description
      1      GL Milk
      1      GL Milk
      1      GL Milk
      1      GL Milk
      1      GL Milk
</code></pre>

<p>I want to display the product in the datagrid the amount I entered in the quantity box.Do I have to make a loop?</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/software-development/vbnet/58">VB.NET</category>
			<dc:creator>acepeda</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/software-development/vbnet/threads/455061/how-to-repeat-data-entered-to-datagrid</guid>
		</item>
				<item>
			<title>What did you all think of the xbox reveal?</title>
			<link>http://www.daniweb.com/community-center/geeks-lounge/threads/455060/what-did-you-all-think-of-the-xbox-reveal</link>
			<pubDate>Tue, 21 May 2013 18:05:42 +0000</pubDate>
			<description>What did you all think of the xbox reveal?</description>
			<content:encoded><![CDATA[ <p>What did you all think of the xbox reveal?</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/community-center/geeks-lounge/6">Geeks' Lounge</category>
			<dc:creator>mat1998x</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/community-center/geeks-lounge/threads/455060/what-did-you-all-think-of-the-xbox-reveal</guid>
		</item>
				<item>
			<title>Does the RSS works well?</title>
			<link>http://www.daniweb.com/community-center/daniweb-community-feedback/threads/455059/does-the-rss-works-well</link>
			<pubDate>Tue, 21 May 2013 18:01:42 +0000</pubDate>
			<description>Hi everyone, I cannot subscribe to rss daniweb com/rss/pull/36/websites-for-sale at daniweb com/business-exchange/webmaster-marketplace/websites-for-sale/_/36 section May you help me with that?</description>
			<content:encoded><![CDATA[ <p>Hi everyone,</p>

<p>I cannot subscribe to rss daniweb com/rss/pull/36/websites-for-sale at  daniweb com/business-exchange/webmaster-marketplace/websites-for-sale/_/36 section</p>

<p>May you help me with that?</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/community-center/daniweb-community-feedback/26">DaniWeb Community Feedback</category>
			<dc:creator>BestDeals</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/community-center/daniweb-community-feedback/threads/455059/does-the-rss-works-well</guid>
		</item>
				<item>
			<title>Scroll View</title>
			<link>http://www.daniweb.com/software-development/java/threads/455058/scroll-view</link>
			<pubDate>Tue, 21 May 2013 17:12:13 +0000</pubDate>
			<description>I'm trying to create a multiple choice quiz, and I need the content pane to scroll. If you run the program I've attached you'll see what I mean. Each question and the answers are place in a JPanel and the JPanels are place on the content pane. Thanks in advance ...</description>
			<content:encoded><![CDATA[ <p>I'm trying to create a multiple choice quiz, and I need the content pane to scroll.  If you run the program I've attached you'll see what I mean.  Each question and the answers are place in a JPanel and the JPanels are place on the content pane.  Thanks in advance for any help.</p>

<pre><code class="language-java">/*********************************************
        Multiple Choice Quiz
*********************************************/
import javax.swing.*;
import javax.swing.event.*;
import java.awt.*;
import java.awt.event.*;
import javax.swing.border.EtchedBorder;

public class Quiz extends JFrame {
    /*********************
      Instance variables
    **********************/

        // Label and answer choices for question1 and JPanel to place components
    private JLabel header, question1;
    private JRadioButton answer1, answer2, answer3, answer4;
    private ButtonGroup question1Group;
    private JPanel question1JPanel;

        // question2
    private JLabel question2;
    private JRadioButton answer5, answer6, answer7, answer8;
    private ButtonGroup question2Group;
    private JPanel question2JPanel;

        // question3
    private JLabel question3;
    private JRadioButton answer9, answer10, answer11, answer12;
    private ButtonGroup question3Group;
    private JPanel question3JPanel;

        // question4
    private JLabel question4;
    private JRadioButton answer13, answer14, answer15, answer16;
    private ButtonGroup question4Group;
    private JPanel question4JPanel;

    /***********************
            Constructor
    ************************/
    public Quiz() {

        // get content pane for attaching GUI components
       Container contentPane = getContentPane();

        // enable explicit positioning of GUI components and set background color
       contentPane.setLayout( null );
        contentPane.setBackground(new Color(77, 0, 64));

        // Label for header
        header = new JLabel( "Linear Equations Quiz" );
        header.setBounds( 10, 5, 980, 24 );
        header.setOpaque( true );                      // for some components you must setOpaque
        header.setBackground( new Color(51, 0, 77) );  // to true before you can change the background color
        header.setForeground(Color.white);
        header.setBorder( BorderFactory.createRaisedBevelBorder() );
        contentPane.add( header );

        // Label for question1
        question1 = new JLabel("1) This is the question");
        question1.setBounds( 1, 5, 272, 24 );
        question1.setForeground(Color.white);
        question1.setBorder( BorderFactory.createEtchedBorder(EtchedBorder.RAISED) );

        // Create answer radioButtons for question1
        answer1 = new JRadioButton("answer #1");
        answer1.setBounds( 1, 30, 200, 24 );
        answer1.setForeground(Color.white);
        answer2 = new JRadioButton("answer #2");
        answer2.setBounds( 1, 55, 200, 24 );
        answer2.setForeground(Color.white);
        answer3 = new JRadioButton("answer #3");
        answer3.setBounds( 1, 80, 200, 24 );
        answer3.setForeground(Color.white);
        answer4 = new JRadioButton("answer #4");
        answer4.setBounds( 1, 105, 200, 24 );
        answer4.setForeground(Color.white);

        // Group answers for question1 together
        question1Group = new ButtonGroup();
        question1Group.add(answer1);
        question1Group.add(answer2);
        question1Group.add(answer3);
        question1Group.add(answer4);

        // set up JPanel (line 84: set place of object on contentPane(first parameter)
        // and line 88: enable explicit placement of GUI components)
      question1JPanel = new JPanel();
      question1JPanel.setBounds( 25, 35, 950, 150 );
        question1JPanel.setBackground( new Color(77, 0, 26) );
        question1JPanel.setForeground(Color.white);
      question1JPanel.setBorder( BorderFactory.createRaisedBevelBorder() );
      question1JPanel.setLayout( null );


        // add question label and add individual JRadioButtons to JPanel
        // (can't add ButtonGroup object to JPanel)
        question1JPanel.add( question1 );
        question1JPanel.add( answer1 );
        question1JPanel.add( answer2 );
        question1JPanel.add( answer3 );
        question1JPanel.add( answer4 );

        // add the question JPanel to the content pane
      contentPane.add( question1JPanel );

        /*************************************************
                    QUESTION2
        *************************************************/
        // Label for question2
        question2 = new JLabel("1) This is the  second question");
        question2.setBounds( 1, 5, 272, 24 );
        question2.setForeground(Color.white);
        question2.setBorder( BorderFactory.createEtchedBorder(EtchedBorder.RAISED) );

        // Create answer radioButtons for question2
        answer5 = new JRadioButton("answer #5");
        answer5.setBounds( 1, 30, 200, 24 );
        answer5.setForeground(Color.white);
        answer6 = new JRadioButton("answer #6");
        answer6.setBounds( 1, 55, 200, 24 );
        answer6.setForeground(Color.white);
        answer7 = new JRadioButton("answer #7");
        answer7.setBounds( 1, 80, 200, 24 );
        answer7.setForeground(Color.white);
        answer8 = new JRadioButton("answer #8");
        answer8.setBounds( 1, 105, 200, 24 );
        answer8.setForeground(Color.white);

        // Group answers for question2 together
        question2Group = new ButtonGroup();
        question2Group.add(answer5);
        question2Group.add(answer6);
        question2Group.add(answer7);
        question2Group.add(answer8);

        // set up JPanel (line 84: set place of object on contentPane(first parameter)
        // and line 88: enable explicit placement of GUI components)
      question2JPanel = new JPanel();
      question2JPanel.setBounds( 25, 195, 950, 150 );
        question2JPanel.setBackground( new Color(77, 0, 26) );
        question2JPanel.setForeground(Color.white);
      question2JPanel.setBorder( BorderFactory.createRaisedBevelBorder() );
      question2JPanel.setLayout( null );


        // add question label and add individual JRadioButtons to JPanel
        // (can't add ButtonGroup object to JPanel)
        question2JPanel.add( question2 );
        question2JPanel.add( answer5 );
        question2JPanel.add( answer6 );
        question2JPanel.add( answer7 );
        question2JPanel.add( answer8 );

        // add the question JPanel to the content pane
      contentPane.add( question2JPanel );

        /*************************************************
                    QUESTION3
        *************************************************/
        // Label for question3
        question3 = new JLabel("1) This is the  third question");
        question3.setBounds( 1, 5, 272, 24 );
        question3.setForeground(Color.white);
        question3.setBorder( BorderFactory.createEtchedBorder(EtchedBorder.RAISED) );

        // Create answer radioButtons for question3
        answer9 = new JRadioButton("answer #9");
        answer9.setBounds( 1, 30, 200, 24 );
        answer9.setForeground(Color.white);
        answer10 = new JRadioButton("answer #10");
        answer10.setBounds( 1, 55, 200, 24 );
        answer10.setForeground(Color.white);
        answer11 = new JRadioButton("answer #11");
        answer11.setBounds( 1, 80, 200, 24 );
        answer11.setForeground(Color.white);
        answer12 = new JRadioButton("answer #12");
        answer12.setBounds( 1, 105, 200, 24 );
        answer12.setForeground(Color.white);

        // Group answers for question2 together
        question3Group = new ButtonGroup();
        question3Group.add(answer9);
        question3Group.add(answer10);
        question3Group.add(answer11);
        question3Group.add(answer12);

        // set up JPanel 
      question3JPanel = new JPanel();
      question3JPanel.setBounds( 25, 355, 950, 150 );
        question3JPanel.setBackground( new Color(77, 0, 26) );
        question3JPanel.setForeground(Color.white);
      question3JPanel.setBorder( BorderFactory.createRaisedBevelBorder() );
      question3JPanel.setLayout( null );

        question3JPanel.add( question3 );
        question3JPanel.add( answer9 );
        question3JPanel.add( answer10 );
        question3JPanel.add( answer11 );
        question3JPanel.add( answer12 );

      contentPane.add( question3JPanel );
        /*************************************************
                    QUESTION4
        *************************************************/
        // Label for question4
        question4 = new JLabel("1) This is the fourth question");
        question4.setBounds( 1, 5, 272, 24 );
        question4.setForeground(Color.white);
        question4.setBorder( BorderFactory.createEtchedBorder(EtchedBorder.RAISED) );

        // Create answer radioButtons for question3
        answer13 = new JRadioButton("answer #13");
        answer13.setBounds( 1, 30, 200, 24 );
        answer13.setForeground(Color.white);
        answer14 = new JRadioButton("answer #14");
        answer14.setBounds( 1, 55, 200, 24 );
        answer14.setForeground(Color.white);
        answer15 = new JRadioButton("answer #15");
        answer15.setBounds( 1, 80, 200, 24 );
        answer15.setForeground(Color.white);
        answer16 = new JRadioButton("answer #16");
        answer16.setBounds( 1, 105, 200, 24 );
        answer16.setForeground(Color.white);

        // Group answers for question2 together
        question4Group = new ButtonGroup();
        question4Group.add(answer13);
        question4Group.add(answer14);
        question4Group.add(answer15);
        question4Group.add(answer16);

        // set up JPanel 
      question4JPanel = new JPanel();
      question4JPanel.setBounds( 25, 515, 950, 150 );
        question4JPanel.setBackground( new Color(77, 0, 26) );
        question4JPanel.setForeground(Color.white);
      question4JPanel.setBorder( BorderFactory.createRaisedBevelBorder() );
      question4JPanel.setLayout( null );

        question4JPanel.add( question4 );
        question4JPanel.add( answer13 );
        question4JPanel.add( answer14 );
        question4JPanel.add( answer15 );
        question4JPanel.add( answer16 );

      contentPane.add( question4JPanel );

        // set properties of application's window
       setTitle( "Quiz" );   // set title bar string
       setSize( 1000, 575 );  // set window size
       setVisible( true );   // display window
        setDefaultCloseOperation(EXIT_ON_CLOSE);// closes program when user exits

    }

    /************************
            Main Method
    *************************/
    public static void main( String[] args )
    {
        Quiz quiz = new Quiz();
    }

}
</code></pre>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/software-development/java/9">Java</category>
			<dc:creator>Dane2259</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/software-development/java/threads/455058/scroll-view</guid>
		</item>
				<item>
			<title>ImagickException memory allocation failed</title>
			<link>http://www.daniweb.com/web-development/php/threads/455057/imagickexception-memory-allocation-failed</link>
			<pubDate>Tue, 21 May 2013 17:05:50 +0000</pubDate>
			<description>Hi all, I have been getting ImagickException with imagick on my server but cannot reproduce it on my computer(localhost). This is when I try to call thumbnailImage(with, height, true) for a JPG exception 'ImagickException' with message 'Memory allocation failed `/tmp/funYYmdPl[0]' @ cache.c/AcquireCacheNexusPixels/416' This is when I call writeImages(path, true) for ...</description>
			<content:encoded><![CDATA[ <p>Hi all,</p>

<p>I have been getting ImagickException with imagick on my server but cannot reproduce it on my computer(localhost).</p>

<p>This is when I try to call thumbnailImage(with, height, true) for a JPG</p>

<p>exception 'ImagickException' with message 'Memory allocation failed <code>/tmp/funYYmdPl[0]' @ cache.c/AcquireCacheNexusPixels/416'
This is when I call writeImages(path, true) for a GIF
exception 'ImagickException' with message 'Memory allocation failed</code>/home/funsub/public_html/uploads/gif/45/45544.gif' @ gif.c/WriteGIFImage/1605'</p>

<p>These are my specs:<br />
ImageMagick 6.5.4-7 2012-05-07 Q16<br />
imagick module version 3.0.1<br />
PHP 5.3.24</p>

<p>I'm on VPS and have set disk usage and bandwidth for that cpanel to unlimited.</p>

<p>I've also tried increasing the php ram usage as well, the problem still occurs.</p>

<p>[root@server ~]# df -h<br />
Filesystem Size Used Avail Use% Mounted on<br />
/dev/vda3 72G 16G 54G 23% /<br />
tmpfs 427M 0 427M 0% /dev/shm<br />
/dev/vda1 195M 76M 110M 41% /boot<br />
/usr/tmpDSK 622M 50M 541M 9% /tmp</p>

<p>Any ideas why?</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/web-development/php/17">PHP</category>
			<dc:creator>wplay</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/web-development/php/threads/455057/imagickexception-memory-allocation-failed</guid>
		</item>
				<item>
			<title>Help beginner with project</title>
			<link>http://www.daniweb.com/software-development/threads/455056/help-beginner-with-project</link>
			<pubDate>Tue, 21 May 2013 16:45:52 +0000</pubDate>
			<description>Need to do for school something that involves: &quot;Your final project must include at least two components from our study, which are CPU (ALU), memory (memory address, stack), and interface (input/output). Control part (Flag register application)is the optional choice.&quot; Any ideas or cool scripts in C/C++ or Linux HLA? Thanks ...</description>
			<content:encoded><![CDATA[ <p>Need to do for school something that involves: "Your final project must include at least two components from our study, which are CPU (ALU), memory (memory address, stack),  and interface (input/output). Control part (Flag register application)is the optional choice."</p>

<p>Any ideas or cool scripts in C/C++ or Linux HLA? Thanks for any help! :)</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/software-development/2">Software Development</category>
			<dc:creator>pabdylos</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/software-development/threads/455056/help-beginner-with-project</guid>
		</item>
				<item>
			<title>remove xmlurl from flash mp3 player</title>
			<link>http://www.daniweb.com/software-development/xml-xslt-and-xpath/threads/455055/remove-xmlurl-from-flash-mp3-player</link>
			<pubDate>Tue, 21 May 2013 16:38:07 +0000</pubDate>
			<description>Hi to all I got flash mp3 player from my friend and I wanna your help becuase I'm not well flash and my friend was moved to Africa, here the actionscripts 2.0 code. my question is I don't to use the plalist.xml file I want to use direct link in ...</description>
			<content:encoded><![CDATA[ <p>Hi to all I got flash mp3 player from my friend and I wanna your help becuase I'm not well flash and my friend was moved to Africa, here the actionscripts 2.0 code.</p>

<p>my question is I don't to use the plalist.xml file I want to use direct link in the embed code<br />
( name=flashvar value="xmlurl=song.mp3-- to value="mp3=<a href="http://mysite.com/song.mp3" rel="nofollow">http://mysite.com/song.mp3</a> instead"</p>

<p>player.fla<br />
player.swf<br />
playlist.xml</p>

<pre><code class="language-xml">stop();

var songs:Array = new Array();
var curtrack:Number = 0;
var playingsong:Sound = new Sound();
var _play:Boolean = false;
var playlistXml:XML = new XML();

if (_level0.xmlURL == undefined)
{
    xmlURL = _level0.xmlURL;
}
else
{
    xmlURL = _level0.xmlURL;
}

playlistXml.ignoreWhite = true;
playlistXml.load(xmlURL);
indicator.gotoAndStop(1);
progressslider._visible = false;
songtime._visible = false;
songtime_2._visible = false;
playpause.playpausebutton.onPress = function()
{
    load_song();
};

function load_song()
{
    loadSongs();
    loadSong(curtrack);
    _play = true;
    progressslider._visible = true;
    indicator.play();
    songtime._visible = true;
    songtime_2._visible = true;
}

function loadSongs()
{
    for (songIndex = 0; songIndex &lt; playlistXml.childNodes[0].childNodes[0].childNodes.length; songIndex++)
    {
        var songdata:Object = new Object();
        for (songNode = 0; songNode &lt; playlistXml.childNodes[0].childNodes[0].childNodes[songIndex].childNodes.length; songNode++)
        {
            switch (playlistXml.childNodes[0].childNodes[0].childNodes[songIndex].childNodes[songNode].nodeName)
            {
                case "creator" :
                    songdata.artist = playlistXml.childNodes[0].childNodes[0].childNodes[songIndex].childNodes[songNode].childNodes[0].nodeValue;
                    break;
                case "title" :
                    songdata.title = playlistXml.childNodes[0].childNodes[0].childNodes[songIndex].childNodes[songNode].childNodes[0].nodeValue;
                    break;
                case "location" :
                    songdata.location = playlistXml.childNodes[0].childNodes[0].childNodes[songIndex].childNodes[songNode].childNodes[0].nodeValue;
                    break;
            }
        }
        songs[songIndex] = songdata;
    }
}

function loadSong(track)
{
    playingsong = new Sound();
    playingsong.loadSound(songs[track].location,true);
    playingsong.start();
    updatevolume();
    playingsong.onSoundComplete = function()
    {
        playpause.gotoAndStop(1);
        indicator.gotoAndStop(1);
        playpause.playpausebutton.onPress = function()
        {
            loadSongs();
            loadSong(curtrack);
        };
    };
    playpause.gotoAndStop(2);
    indicator.play();
    playpause.playpausebutton.onPress = function()
    {
        toggleplaypause();
    };
    songdisplay.text = songs[track].artist + " - " + songs[track].title;
    eval("playlistbox.playlistitemcontainer.playlistitem" + curtrack + ".playlistitemhighlight")._alpha = 4;
    eval("playlistbox.playlistitemcontainer.playlistitem" + track + ".playlistitemhighlight")._alpha = 20;
    curtrack = track;
}

function toggleplaypause()
{
    if (playpause._currentframe == 1)
    {
        playpause.gotoAndStop(2);
        playpause.curpos = playingsong.position;
        playingsong.start(playpause.curpos / 1000,0);
        indicator.play();
    }
    else
    {
        playpause.gotoAndStop(1);
        playingsong.stop();
        indicator.stop();
    }
    playpause.playpausebutton.onPress = function()
    {
        toggleplaypause();
    };
}

onEnterFrame = function ()
{
    if (!draggingslider)
    {
        progressslider._x = (playingsong.position / playingsong.duration) * 249 + 130;
        if (progressslider._x == 0)
        {
            progressslider._x = 130;
        }
    }
    if (draggingvolmeslider)
    {
        updatevolume();
    }
    tempsongtime = "";
    if (Math.floor(playingsong.position / 60000) == 0)
    {
        tempsongtime += "0";
    }
    else
    {
        tempsongtime += Math.floor(playingsong.position / 60000);
    }
    tempsongtime += ":";
    if (Math.floor((playingsong.position / 1000) % 60) &lt; 10)
    {
        tempsongtime += "0";
    }
    tempsongtime += Math.floor((playingsong.position / 1000) % 60);
    tempsongtime += "                                                         ";
    if (Math.floor(playingsong.duration / 60000) == 0)
    {
        tempsongtime += "0";
    }
    else
    {
        tempsongtime += Math.floor(playingsong.duration / 60000);
    }
    tempsongtime += ":";
    if (Math.floor((playingsong.duration / 1000) % 60) &lt; 10)
    {
        tempsongtime += "0";
    }
    tempsongtime += Math.floor((playingsong.duration / 1000) % 60);
    songtime.text = tempsongtime;
    tempsongtime_2 = "";
    tempsongtime_2 += "";
    if (Math.floor(playingsong.duration / 60000) == 0)
    {
        tempsongtime_2 += "0";
    }
    else
    {
        tempsongtime_2 += Math.floor(playingsong.duration / 60000);
    }
    tempsongtime_2 += ":";
    if (Math.floor((playingsong.duration / 1000) % 60) &lt; 10)
    {
        tempsongtime_2 += "0";
    }
    tempsongtime_2 += Math.floor((playingsong.duration / 1000) % 60);
    songtime_2.text = tempsongtime_2;
};

progressslider.onPress = function()
{
    draggingslider = true;
    progressslider.startDrag(true,130,progressslider._y,374,progressslider._y);
};

progressslider.onRelease = progressslider.onReleaseOutside = function ()
{
    if (_play)
    {
        progressslider.stopDrag();
        playingsong.start(((progressslider._x - 130) / 249) * playingsong.duration / 1000,0);
        playpause.gotoAndStop(2);
        indicator.play();
        playpause.playpausebutton.onPress = function()
        {
            toggleplaypause();
        };
        draggingslider = false;
    }
};
progressbar.onPress = function()
{
    if (_play)
    {
        playingsong.start(((_xmouse - 130) / 249) * playingsong.duration / 1000,0);
        playpause.gotoAndStop(2);
        indicator.play();
        playpause.playpausebutton.onPress = function()
        {
            toggleplaypause();
        };
    }
};

volumebar.onPress = function()
{
    draggingvolmeslider = true;
    volumebar.volumeslider.startDrag(true,0,volumebar.volumeslider._y,47,volumebar.volumeslider._y);
};

volumebar.onRelease = volumebar.onReleaseOutside = function ()
{
    draggingvolmeslider = false;
    volumebar.volumeslider.stopDrag();
    updatevolume();
};

function updatevolume()
{
    playingsong.setVolume((volumebar.volumeslider._x / 47) * 100);
}stop();

var songs:Array = new Array();
var curtrack:Number = 0;
var playingsong:Sound = new Sound();
var _play:Boolean = false;
var playlistXml:XML = new XML();

if (_level0.xmlURL == undefined)
{
    xmlURL = _level0.xmlURL;
}
else
{
    xmlURL = _level0.xmlURL;
}

playlistXml.ignoreWhite = true;
playlistXml.load(xmlURL);
indicator.gotoAndStop(1);
progressslider._visible = false;
songtime._visible = false;
songtime_2._visible = false;
playpause.playpausebutton.onPress = function()
{
    load_song();
};

function load_song()
{
    loadSongs();
    loadSong(curtrack);
    _play = true;
    progressslider._visible = true;
    indicator.play();
    songtime._visible = true;
    songtime_2._visible = true;
}

function loadSongs()
{
    for (songIndex = 0; songIndex &lt; playlistXml.childNodes[0].childNodes[0].childNodes.length; songIndex++)
    {
        var songdata:Object = new Object();
        for (songNode = 0; songNode &lt; playlistXml.childNodes[0].childNodes[0].childNodes[songIndex].childNodes.length; songNode++)
        {
            switch (playlistXml.childNodes[0].childNodes[0].childNodes[songIndex].childNodes[songNode].nodeName)
            {
                case "creator" :
                    songdata.artist = playlistXml.childNodes[0].childNodes[0].childNodes[songIndex].childNodes[songNode].childNodes[0].nodeValue;
                    break;
                case "title" :
                    songdata.title = playlistXml.childNodes[0].childNodes[0].childNodes[songIndex].childNodes[songNode].childNodes[0].nodeValue;
                    break;
                case "location" :
                    songdata.location = playlistXml.childNodes[0].childNodes[0].childNodes[songIndex].childNodes[songNode].childNodes[0].nodeValue;
                    break;
            }
        }
        songs[songIndex] = songdata;
    }
}

function loadSong(track)
{
    playingsong = new Sound();
    playingsong.loadSound(songs[track].location,true);
    playingsong.start();
    updatevolume();
    playingsong.onSoundComplete = function()
    {
        playpause.gotoAndStop(1);
        indicator.gotoAndStop(1);
        playpause.playpausebutton.onPress = function()
        {
            loadSongs();
            loadSong(curtrack);
        };
    };
    playpause.gotoAndStop(2);
    indicator.play();
    playpause.playpausebutton.onPress = function()
    {
        toggleplaypause();
    };
    songdisplay.text = songs[track].artist + " - " + songs[track].title;
    eval("playlistbox.playlistitemcontainer.playlistitem" + curtrack + ".playlistitemhighlight")._alpha = 4;
    eval("playlistbox.playlistitemcontainer.playlistitem" + track + ".playlistitemhighlight")._alpha = 20;
    curtrack = track;
}

function toggleplaypause()
{
    if (playpause._currentframe == 1)
    {
        playpause.gotoAndStop(2);
        playpause.curpos = playingsong.position;
        playingsong.start(playpause.curpos / 1000,0);
        indicator.play();
    }
    else
    {
        playpause.gotoAndStop(1);
        playingsong.stop();
        indicator.stop();
    }
    playpause.playpausebutton.onPress = function()
    {
        toggleplaypause();
    };
}

onEnterFrame = function ()
{
    if (!draggingslider)
    {
        progressslider._x = (playingsong.position / playingsong.duration) * 249 + 130;
        if (progressslider._x == 0)
        {
            progressslider._x = 130;
        }
    }
    if (draggingvolmeslider)
    {
        updatevolume();
    }
    tempsongtime = "";
    if (Math.floor(playingsong.position / 60000) == 0)
    {
        tempsongtime += "0";
    }
    else
    {
        tempsongtime += Math.floor(playingsong.position / 60000);
    }
    tempsongtime += ":";
    if (Math.floor((playingsong.position / 1000) % 60) &lt; 10)
    {
        tempsongtime += "0";
    }
    tempsongtime += Math.floor((playingsong.position / 1000) % 60);
    tempsongtime += "                                                         ";
    if (Math.floor(playingsong.duration / 60000) == 0)
    {
        tempsongtime += "0";
    }
    else
    {
        tempsongtime += Math.floor(playingsong.duration / 60000);
    }
    tempsongtime += ":";
    if (Math.floor((playingsong.duration / 1000) % 60) &lt; 10)
    {
        tempsongtime += "0";
    }
    tempsongtime += Math.floor((playingsong.duration / 1000) % 60);
    songtime.text = tempsongtime;
    tempsongtime_2 = "";
    tempsongtime_2 += "";
    if (Math.floor(playingsong.duration / 60000) == 0)
    {
        tempsongtime_2 += "0";
    }
    else
    {
        tempsongtime_2 += Math.floor(playingsong.duration / 60000);
    }
    tempsongtime_2 += ":";
    if (Math.floor((playingsong.duration / 1000) % 60) &lt; 10)
    {
        tempsongtime_2 += "0";
    }
    tempsongtime_2 += Math.floor((playingsong.duration / 1000) % 60);
    songtime_2.text = tempsongtime_2;
};

progressslider.onPress = function()
{
    draggingslider = true;
    progressslider.startDrag(true,130,progressslider._y,374,progressslider._y);
};

progressslider.onRelease = progressslider.onReleaseOutside = function ()
{
    if (_play)
    {
        progressslider.stopDrag();
        playingsong.start(((progressslider._x - 130) / 249) * playingsong.duration / 1000,0);
        playpause.gotoAndStop(2);
        indicator.play();
        playpause.playpausebutton.onPress = function()
        {
            toggleplaypause();
        };
        draggingslider = false;
    }
};
progressbar.onPress = function()
{
    if (_play)
    {
        playingsong.start(((_xmouse - 130) / 249) * playingsong.duration / 1000,0);
        playpause.gotoAndStop(2);
        indicator.play();
        playpause.playpausebutton.onPress = function()
        {
            toggleplaypause();
        };
    }
};

volumebar.onPress = function()
{
    draggingvolmeslider = true;
    volumebar.volumeslider.startDrag(true,0,volumebar.volumeslider._y,47,volumebar.volumeslider._y);
};

volumebar.onRelease = volumebar.onReleaseOutside = function ()
{
    draggingvolmeslider = false;
    volumebar.volumeslider.stopDrag();
    updatevolume();
};

function updatevolume()
{
    playingsong.setVolume((volumebar.volumeslider._x / 47) * 100);
}
</code></pre>

<p>I hope you understand my question and will help me</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/software-development/xml-xslt-and-xpath/134">XML, XSLT and XPATH</category>
			<dc:creator>bashaash</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/software-development/xml-xslt-and-xpath/threads/455055/remove-xmlurl-from-flash-mp3-player</guid>
		</item>
				<item>
			<title>Thread tags and newbies</title>
			<link>http://www.daniweb.com/community-center/daniweb-community-feedback/threads/455053/thread-tags-and-newbies</link>
			<pubDate>Tue, 21 May 2013 15:36:47 +0000</pubDate>
			<description>Lately I have seen several threads that people have &quot;tagged&quot; as intended. Why is *tagged* in quotes? Because instead of putting *keywords* into the tags box, users are describing the question they're asking in the thread, and thus creating tags that look this way: **Time zone** `how` `to` `find` `frame` ...</description>
			<content:encoded><![CDATA[ <p>Lately I have seen several threads that people have "tagged" as intended. Why is <em>tagged</em> in quotes? Because instead of putting <em>keywords</em> into the tags box, users are describing the question they're asking in the thread, and thus creating tags that look this way:</p>

<p><strong>Time zone</strong><br /><code>how</code> <code>to</code> <code>find</code> <code>frame</code> <code>a</code> <code>standardize</code> <code>date</code> <code>time</code> <code>common</code> <code>for</code> <code>various</code> <code>zone?</code></p>

<p><strong>I cant create code login</strong><br /><code>3</code> <code>users</code> <code>using</code> <code>the</code> <code>login</code> <code>page</code></p>

<p><strong>How to cancel an add operation</strong><br /><code>cancel</code> <code>add</code> <code>operation</code> <code>and</code> <code>display</code> <code>last</code> <code>record</code> <code>from</code> <code>recordset</code></p>

<p>So, here's my suggestion: Make it so that when the user types a new tag, after hitting spacebar triggers an event that turns the last word into a 'tag' element/box/whatever. That way, there's a more clear idea that what you're inputting into the textbox are tags, and is not meant for a sentence or a description.</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/community-center/daniweb-community-feedback/26">DaniWeb Community Feedback</category>
			<dc:creator>Nichito</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/community-center/daniweb-community-feedback/threads/455053/thread-tags-and-newbies</guid>
		</item>
				<item>
			<title>how to cancel an add operation</title>
			<link>http://www.daniweb.com/software-development/visual-basic-4-5-6/threads/455052/how-to-cancel-an-add-operation</link>
			<pubDate>Tue, 21 May 2013 15:29:15 +0000</pubDate>
			<description>hi, i am working on development of a software project. i have used VB6.0 as frontend and MS Access as backend. In my project i have made a form in which i have to add,delete,search,move first,move last,move next and move previous options to keep tack of employee details. I want ...</description>
			<content:encoded><![CDATA[ <p>hi,<br />
i am working on development of a software project. i have used VB6.0 as frontend and MS Access as backend. In my project i have made a form in which i have to add,delete,search,move first,move last,move next and move  previous options to  keep tack of employee details. I want to know once i hve clicked on command button for "add record" and cancel he operation in between  what wil be the code for cancelling add operation.?<br />
how to cancel this operation and return back to  display the last recordd?<br />
need help as \soon as possible....thank you in advance</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/software-development/visual-basic-4-5-6/4">Visual Basic 4 / 5 / 6</category>
			<dc:creator>vinitatiska</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/software-development/visual-basic-4-5-6/threads/455052/how-to-cancel-an-add-operation</guid>
		</item>
				<item>
			<title>i cant create the code to login</title>
			<link>http://www.daniweb.com/web-development/php/threads/455051/i-cant-create-the-code-to-login</link>
			<pubDate>Tue, 21 May 2013 15:00:01 +0000</pubDate>
			<description> &lt;!DOCTYPE html PUBLIC &quot;-//WAPFORUM//DTD XHTML Mobile 1.0//EN&quot; &quot;http://www.wapforum.org/DTD/xhtml-mobile10.dtd&quot;&gt; &lt;html xmlns=&quot;http://www.w3.org/1999/xhtml&quot;&gt; &lt;head&gt; &lt;link rel=&quot;icon&quot; type=&quot;image/png&quot; href=&quot;images/ump-logo.png&quot; /&gt; &lt;meta charset=&quot;utf-8&quot;&gt; &lt;meta name=&quot;viewport&quot; content=&quot;width=device-width, initial-scale=1&quot;&gt; &lt;title&gt;Universiti Malaysia Sabah&lt;/title&gt; &lt;link rel=&quot;stylesheet&quot; href=&quot;jquery.mobile-1.0.min.css&quot; /&gt; &lt;link rel=&quot;stylesheet&quot; href=&quot;_assets/css/jqm-docs.css&quot;/&gt; &lt;script src=&quot;jquery.js&quot;&gt;&lt;/script&gt; &lt;script src=&quot;_assets/js/jqm-docs.js&quot;&gt;&lt;/script&gt; &lt;script src=&quot;jquery.mobile-1.0.min.js&quot;&gt;&lt;/script&gt; &lt;/head&gt; &lt;body&gt; &lt;div data-role=&quot;page&quot; class=&quot;type-index&quot;&gt; &lt;div data-role=&quot;header&quot; data-theme=&quot;f&quot;&gt; &lt;h1&gt;Sistem Kompaun Pelajar&lt;/h1&gt; &lt;a ...</description>
			<content:encoded><![CDATA[ <pre><code>&lt;!DOCTYPE html PUBLIC "-//WAPFORUM//DTD XHTML Mobile 1.0//EN" "<a href="http://www.wapforum.org/DTD/xhtml-mobile10.dtd" rel="nofollow">http://www.wapforum.org/DTD/xhtml-mobile10.dtd</a>"&gt; 
&lt;html xmlns="<a href="http://www.w3.org/1999/xhtml" rel="nofollow">http://www.w3.org/1999/xhtml</a>"&gt;  
    &lt;head&gt;
        &lt;link rel="icon" 
      type="image/png" 
      href="images/ump-logo.png" /&gt;
    &lt;meta charset="utf-8"&gt;
    &lt;meta name="viewport" content="width=device-width, initial-scale=1"&gt; 
    &lt;title&gt;Universiti Malaysia Sabah&lt;/title&gt; 
    &lt;link rel="stylesheet"  href="jquery.mobile-1.0.min.css" /&gt;  
    &lt;link rel="stylesheet" href="_assets/css/jqm-docs.css"/&gt;
    &lt;script src="jquery.js"&gt;&lt;/script&gt;
    &lt;script src="_assets/js/jqm-docs.js"&gt;&lt;/script&gt;
    &lt;script src="jquery.mobile-1.0.min.js"&gt;&lt;/script&gt;
&lt;/head&gt; 
&lt;body&gt; 

    &lt;div data-role="page" class="type-index"&gt;

        &lt;div data-role="header" data-theme="f"&gt;
        &lt;h1&gt;Sistem Kompaun Pelajar&lt;/h1&gt;
            &lt;a href="index.php" data-icon="home" data-iconpos="notext" class="ui-btn-right"&gt;Home&lt;/a&gt;
    &lt;/div&gt;&lt;!-- /header --&gt;

    &lt;div data-role="content"&gt;

        &lt;ul data-role="listview" data-inset="true"&gt;
            &lt;li&gt;Login&lt;/li&gt;
            &lt;li&gt;
            &lt;form name="login" action="login-exec.php" method="post"&gt;
              &lt;label for="basic"&gt;Katanama&lt;/label&gt;

              &lt;label for="basic"&gt;:&lt;/label&gt;
            &lt;input type="text" name="login" id="login" value=""  /&gt;
            &lt;label for="basic"&gt;Katalaluan:&lt;/label&gt;
            &lt;input type="password" name="password" id="password" value=""  /&gt;
            &lt;select name="pilihan" id="pilihan" data-theme="b" data-overlay-theme="d" data-native-menu="false"&gt;
              &lt;option value=""&gt;Kategori&lt;/option&gt;
              &lt;option value="1"&gt;Pelajar&lt;/option&gt;
              &lt;option value="2"&gt;Staf&lt;/option&gt;
              &lt;option value="3"&gt;Admin&lt;/option&gt;
            &lt;/select&gt;
            &lt;button type="submit"&gt;Masuk&lt;/submit&gt;
            &lt;button type="reset"&gt;Padam&lt;/reset&gt;

              &lt;/form&gt;
            &lt;/li&gt;

        &lt;/ul&gt;

    &lt;/div&gt;&lt;!-- /ui-body wrapper --&gt;   
&lt;/div&gt;&lt;!-- /page --&gt;   
&lt;div align="right"&gt;


&lt;/div&gt;
&lt;/body&gt;
&lt;/html&gt;




&lt;?php
    //Start session
    session_start();

    //Include database connection details
    include('config.php');

    //Array to store validation errors
    $errmsg_arr = array();

    //Validation error flag
    $errflag = false;

    //Connect to mysql server
    //$link = mysql_connect(DB_HOST, DB_USER, DB_PASSWORD);
    //if(!$link) {
    //  die('Failed to connect to server: ' . mysql_error());
    //}

    //Select database
    $db = mysql_select_db($db_name);
    if(!$db) {
        die("Unable to select database");
    }

    //Function to sanitize values received from the form. Prevents SQL injection
    function clean($str) {
        $str = @trim($str);
        if(get_magic_quotes_gpc()) {
            $str = stripslashes($str);
        }
        return mysql_real_escape_string($str);
    }

    //Sanitize the POST values
    $login = clean($_POST['login']);
    $password = clean($_POST['password']);
    $pilihan = clean($_POST['pilihan']);

    //Input Validations
    if($login == '') {
        $errmsg_arr[] = 'Login ID missing';
        $errflag = true;
    }
    if($password == '') {
        $errmsg_arr[] = 'Password missing';
        $errflag = true;
    }
    if($pilihan == '') {
        $errmsg_arr[] = 'kesilapan';
        $errflag = true;
    }
    //If there are input validations, redirect back to the login form
    if($errflag) {
        $_SESSION['ERRMSG_ARR'] = $errmsg_arr;
        session_write_close();
        header("location: login.html");
        exit();
    }

    if($pilihan == 1){
    //Create query
    $qry="SELECT * FROM students WHERE user='$login' AND pwd='".md5($_POST['password'])."'";
    $result=mysql_query($qry);

    //Check whether the query was successful or not
    if($result) {
        if(mysql_num_rows($result) == 1) {
            //Login Successful
            session_regenerate_id();
            $member = mysql_fetch_assoc($result);
            $_SESSION['SESS_ID'] = $member['std_id'];
            $_SESSION['SESS_NAME'] = $member['nama'];
            session_write_close();
            header("location: students.php");
            exit();
        }else {
            //Login failed
            header("location: login-failed.html");
            exit();
        }
    }else {
        die("Query failed");
    }
    }
    if($pilihan == 2){
    //Create query
    $qry="SELECT * FROM staff WHERE username='$login' AND password='".md5($_POST['password'])."'";
    $result=mysql_query($qry);

    //Check whether the query was successful or not
    if($result) {
        if(mysql_num_rows($result) == 1) {
            //Login Successful
            session_regenerate_id();
            $member = mysql_fetch_assoc($result);
            $_SESSION['SESS_ID'] = $member['staff_id'];
            $_SESSION['SESS_NAME'] = $member['nama'];
            session_write_close();
            header("location: staff.php");
            exit();
        }else {
            //Login failed
            header("location: login-failed.html");
            exit();
        }
    }else {
        die("Query failed");
    }
    }
    else{
    header("location: login-failed.html");
    }
    if($pilihan == 3){
    //Create query
    $qry="SELECT * FROM admin WHERE username='$login' AND password='".md5($_POST['password'])."'";
    $result=mysql_query($qry);

    //Check whether the query was successful or not
    if($result) {
        if(mysql_num_rows($result) == 1) {
            //Login Successful
            session_regenerate_id();
            $member = mysql_fetch_assoc($result);
            $_SESSION['SESS_ID'] = $member['id'];
            $_SESSION['SESS_NAME'] = $member['nama'];
            session_write_close();
            header("location: admin.php");
            exit();
        }else {
            //Login failed
            header("location: login-failed.html");
            exit();
        }
    }else {
        die("Query failed");
    }
    }
    else{
    header("location: login-failed.html");
    }
?&gt;


//example for table student. the rest almost the same
` varchar(50) NOT NULL,
  `pwd` varchar(50) NOT NULL,
  `nama` varchar(50) NOT NULL,
  `std_id` varchar(50) NOT NULL,
  `std_ic` varchar(50) NOT NULL,
  `sekolah` varchar(50) NOT NULL,
  `kos` varchar(50) NOT NULL,
  `tahun` int(2) NOT NULL,
  PRIMARY KEY (`ID`)
) ENGINE=InnoDB  DEFAULT CHARSET=armscii8 COMMENT='student xda s d ujung k' AUTO_INCREMENT=2 ;





//config.php
&lt;?php
    define('DB_HOST', 'localhost');
    define('DB_USER', 'root');
    define('DB_PASSWORD', '');
    define('DB_DATABASE', 'ca10109');
?&gt;
</code></pre>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/web-development/php/17">PHP</category>
			<dc:creator>aqualove</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/web-development/php/threads/455051/i-cant-create-the-code-to-login</guid>
		</item>
				<item>
			<title>C programming</title>
			<link>http://www.daniweb.com/software-development/cpp/threads/455050/c-programming</link>
			<pubDate>Tue, 21 May 2013 14:42:57 +0000</pubDate>
			<description>Write a C++ program to compute and display a person's monthly salary as determined. If the status is Technician the person receives RM70 perday for 26 days work in a month. If the status is Lecturer the person receives RM200 perday for 26 days work in a month. if the ...</description>
			<content:encoded><![CDATA[ <p>Write a C++ program to compute and display a person's monthly salary as determined. If the status is Technician the person receives RM70 perday for 26 days work in a month. If the status is Lecturer the person receives RM200 perday for 26 days work in a month. if the status is Instructor the person receives RM150 perday for 26 days work in a month. The program should request the status as input and should display the salary ad output.</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/software-development/cpp/8">C++</category>
			<dc:creator>selipar.jepun.712</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/software-development/cpp/threads/455050/c-programming</guid>
		</item>
				<item>
			<title>Best GIF resizing software</title>
			<link>http://www.daniweb.com/web-development/php/threads/455049/best-gif-resizing-software</link>
			<pubDate>Tue, 21 May 2013 14:40:01 +0000</pubDate>
			<description>Hi all, I'm currently using imagemagick to resize gifs for my site. But the compression doesn't seem really good. I've already tried optimizing it the best way I could, but it isn't satisfactory. Does anyone have recommendations for a better option? Tumblr's gif compression seems to be the best I've ...</description>
			<content:encoded><![CDATA[ <p>Hi all,</p>

<p>I'm currently using imagemagick to resize gifs for my site. But the compression doesn't seem really good.</p>

<p>I've already tried optimizing it the best way I could, but it isn't satisfactory. Does anyone have recommendations for a better option?</p>

<p>Tumblr's gif compression seems to be the best I've seen, was hoping if I could achieve similar results.</p>

<p>Thanks!</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/web-development/php/17">PHP</category>
			<dc:creator>wplay</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/web-development/php/threads/455049/best-gif-resizing-software</guid>
		</item>
				<item>
			<title>Ignoring event fires</title>
			<link>http://www.daniweb.com/web-development/javascript-dhtml-ajax/threads/455048/ignoring-event-fires</link>
			<pubDate>Tue, 21 May 2013 14:20:05 +0000</pubDate>
			<description>Hi I have an event listener attached to something which will fire a lot based on some user action that has occured on the page or some javscript change. Unfortunately it will be something like 5 or 6 fires in the space of 250ms and I am only interested in ...</description>
			<content:encoded><![CDATA[ <p>Hi</p>

<p>I have an event listener attached to something which will fire a lot based on some user action that has occured on the page or some javscript change. Unfortunately it will be something like 5 or 6 fires in the space of 250ms and I am only interested in the last fire so I can carry out the resource intensive processing. I'd like to ignore all of the fires before that.</p>

<p>Any way this can be achieved keeping in mind we don't know how many times it will fire.</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/web-development/javascript-dhtml-ajax/117">JavaScript / DHTML / AJAX</category>
			<dc:creator>asif49</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/web-development/javascript-dhtml-ajax/threads/455048/ignoring-event-fires</guid>
		</item>
				<item>
			<title>Can you develop for iphone from windows?</title>
			<link>http://www.daniweb.com/hardware-and-software/apple/ios-iphone-os/threads/455047/can-you-develop-for-iphone-from-windows</link>
			<pubDate>Tue, 21 May 2013 13:56:12 +0000</pubDate>
			<description>So as I posted before I am thinking on buying an iphone. I want to get into mobile app dev. I dont have a mac (only windows) so I search and found a lot of articles that said that it is basicly imposible to write iphone apps from a windows ...</description>
			<content:encoded><![CDATA[ <p>So as I posted before I am thinking on buying an iphone. I want to get into mobile app dev. I dont have a mac (only windows) so I search and found a lot of articles that said that it is basicly imposible to write iphone apps from a windows OS. I really like the iphones but really dont want to buy a mac just to develop for iphone.</p>

<p>Is there realy no way or am I just missing it (as the same was said about c# on linux, then I found monoproject).<br />
And where can I get the development tools from then (for windows).</p>

<p>Thanks</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/hardware-and-software/apple/ios-iphone-os/101">iOS (iPhone OS)</category>
			<dc:creator>MasterHacker110</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/hardware-and-software/apple/ios-iphone-os/threads/455047/can-you-develop-for-iphone-from-windows</guid>
		</item>
				<item>
			<title>Login with other DB</title>
			<link>http://www.daniweb.com/web-development/php/threads/455046/login-with-other-db</link>
			<pubDate>Tue, 21 May 2013 13:42:52 +0000</pubDate>
			<description>Hey all, Been trying to work this out. But I'm stumped! Got a database running on Moodle. Want to create an external script which uses the usernames and passwords from the table moodle_user and the db Profiled_Moodle. Here is my page so far: &lt;?php include 'header/config.php';?&gt; &lt;div id=&quot;Container&quot;&gt; &lt;?php if ...</description>
			<content:encoded><![CDATA[ <p>Hey all,</p>

<p>Been trying to work this out. But I'm stumped!</p>

<p>Got a database running on Moodle. Want to create an external script which uses the usernames and passwords from the table moodle_user and the db Profiled_Moodle.</p>

<p>Here is my page so far:</p>

<pre><code>&lt;?php include 'header/config.php';?&gt;
&lt;div id="Container"&gt;
        &lt;?php
     if ($_POST['submit']) {

        //your dbname
        mysqli_select_db($con,'moodle_user') or die(mysql_error()); 

        $salt = '7(}AouN0sysQF#{]s@[F]Y~b]5E'; //change with your salt
        $password = md5($_POST['password'] . $salt);

    $username = $_POST['username'];


        $query = "SELECT * FROM moodle_user WHERE username = '{$_POST['username']}' AND password = '$password'";

        $result = mysql_query($query) or die(mysql_error());

        echo '&lt;pre&gt;' . $username ;

        while ($row = mysql_fetch_assoc($result)) {
            print_r($row);
            echo 'logged in as:' . $username;
        } 
    } else {
        echo "Not logged in";
    }
    ?&gt;
</code></pre>

<p>The reason I have that salt is because in moodle config.php I have that set.</p>

<pre><code>$CFG-&gt;passwordsaltmain = '7(}AouN0sysQF#{]s@[F]Y~b]5E';
</code></pre>

<p>When I login to the form. Nothing is happening? I'm not getting an echo or print</p>

<p>Thanks guys</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/web-development/php/17">PHP</category>
			<dc:creator>bradly.spicer</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/web-development/php/threads/455046/login-with-other-db</guid>
		</item>
				<item>
			<title>Recursion </title>
			<link>http://www.daniweb.com/software-development/csharp/threads/455045/recursion-</link>
			<pubDate>Tue, 21 May 2013 12:39:23 +0000</pubDate>
			<description>I wast just wondering guys how do you look at recursion , how do you apply it (i m not talking here about easy recursions like hannoi tower, factoriels, fibonnaci... wich are obvious). I m a beginner programmer and i understand the concept quite well but let s say a ...</description>
			<content:encoded><![CDATA[ <p>I  wast just wondering guys how do you look at recursion , how do you apply it (i m not talking here about easy recursions like  hannoi tower, factoriels, fibonnaci... wich are obvious). I m a beginner programmer and i understand the concept quite well but let s say a more complex problem appears than i would have to think hard and yet i would n t know how to apply recusion(in wich order to form the code so the recursion works on it). So my question is will i ever understand recursion, will it ever be the thing that i ll say that it s a piece of cake, and the other question is how did you guys get on with it, how did you understand it, how long did it  take to fully understand(i know that some of you have abstract minds and you pick it up fast..)<br />
PS. I know that tracing recursion is a bad idea.</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/software-development/csharp/61">C#</category>
			<dc:creator>castajiz_2</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/software-development/csharp/threads/455045/recursion-</guid>
		</item>
				<item>
			<title>PC PROBLEM.</title>
			<link>http://www.daniweb.com/hardware-and-software/pc-hardware/motherboards-cpus-and-ram/threads/455044/pc-problem</link>
			<pubDate>Tue, 21 May 2013 12:27:55 +0000</pubDate>
			<description>needing some help about this matter. 1.) i changed the setting on BIOS pressed F10 then reboot and when i checked again the bios the setting i've changed wasn't saved. 2.) after the windows loading screen. it reboots by itself. please help me.</description>
			<content:encoded><![CDATA[ <p>needing some help about this matter.</p>

<p>1.) i changed the setting on BIOS pressed F10 then reboot and when i checked again the bios the setting i've changed wasn't saved.</p>

<p>2.) after the windows loading screen. it reboots by itself.</p>

<p>please help me.</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/hardware-and-software/pc-hardware/motherboards-cpus-and-ram/104">Motherboards, CPUs and RAM</category>
			<dc:creator>aarviii</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/hardware-and-software/pc-hardware/motherboards-cpus-and-ram/threads/455044/pc-problem</guid>
		</item>
				<item>
			<title>&#039;Live&#039; updates of div without hammering server</title>
			<link>http://www.daniweb.com/web-development/javascript-dhtml-ajax/threads/455043/live-updates-of-div-without-hammering-server</link>
			<pubDate>Tue, 21 May 2013 12:18:08 +0000</pubDate>
			<description>We recently had our account suspended (without warning - thanks 1&amp;1) due to exceeding server load. The reason this happened was there were quite a few divs that were refreshing (via Ajax) every 9 seconds to give a 'live update' on the site (it is a sports site so this ...</description>
			<content:encoded><![CDATA[ <p>We recently had our account suspended (without warning - thanks 1&amp;1) due to exceeding server load.</p>

<p>The reason this happened was there were quite a few divs that were refreshing (via Ajax) every 9 seconds to give a 'live update' on the site (it is a sports site so this was to give live score updates etc).</p>

<p>Now I am looking for an alternative way of getting the same functionality without putting strain on the server and, ideally, not register a page hit on each refresh and hopefully someone can give me advice on the best way to go.</p>

<p>Currently, each of these divs call a seperate page which pulls data from a MySQL database. I have read that there are ways to check that file and only refresh the div if it has changed. Ideally, however, I would like to pull the data directly into the div, without using the middle page, and get that to update if the data in the database has changed.</p>

<p>Having said that, I am open to any suggestions or pointers that will give me the same live updates without running the risk of the host pulling the plug again!</p>

<p>Thanks<br />
Steve</p>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/web-development/javascript-dhtml-ajax/117">JavaScript / DHTML / AJAX</category>
			<dc:creator>MargateSteve</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/web-development/javascript-dhtml-ajax/threads/455043/live-updates-of-div-without-hammering-server</guid>
		</item>
				<item>
			<title>Schizophrenia and smoking</title>
			<link>http://www.daniweb.com/community-center/geeks-lounge/threads/455042/schizophrenia-and-smoking</link>
			<pubDate>Tue, 21 May 2013 12:08:06 +0000</pubDate>
			<description>http://en.wikipedia.org/wiki/Schizophrenia_and_smoking &gt; Studies across 20 countries show a strong association between schizophrenia and smoking.[1] For example, in the United States, 80% or more of schizophrenics smoke, compared to 20% of the general population in 2006.[2] &gt; Though it is well established that smoking is more prevalent among schizophrenics than the ...</description>
			<content:encoded><![CDATA[ <p><a href="http://en.wikipedia.org/wiki/Schizophrenia_and_smoking" rel="nofollow">http://en.wikipedia.org/wiki/Schizophrenia_and_smoking</a></p>

<blockquote>
  <p>Studies across 20 countries show a strong association between schizophrenia and smoking.[1] For example, in the United States, 80% or more of schizophrenics smoke, compared to 20% of the general population in 2006.[2]</p>
  
  <p>Though it is well established that smoking is more prevalent among schizophrenics than the general population as well as those with other psychiatric diagnoses, there is currently no definitive explanation for this difference.[3] Many social, psychological, and biological explanations have been proposed, but today research focuses on neurobiology.</p>
</blockquote>
 ]]></content:encoded>
			<category domain="http://www.daniweb.com/community-center/geeks-lounge/6">Geeks' Lounge</category>
			<dc:creator>Xantipius</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/community-center/geeks-lounge/threads/455042/schizophrenia-and-smoking</guid>
		</item>
			</channel>
</rss>