KuroTsuto's Profile User Rating: -----

Reputation: 42 Craftsman
Group:
Contributors
Active Posts:
182 (0.12 per day)
Joined:
13-February 09
Profile Views:
4,799
Last Active:
User is offline May 08 2013 01:30 AM
Currently:
Offline

Previous Fields

Country:
US
OS Preference:
Linux
Favorite Browser:
Chrome
Favorite Processor:
Intel
Favorite Gaming Platform:
XBox
Your Car:
Jeep
Dream Kudos:
50

Latest Visitors

Icon   KuroTsuto has not set their status

Posts I've Made

  1. In Topic: PHP ssh

    Posted 22 Jan 2012

    View Postcompactbrain, on 21 January 2012 - 06:28 PM, said:

    I want to read from a gps and either save to file or send directly. I am making the assumption that the gps sends data like "55,12,33.462;23,4,2.268" just for ease. So if I had a gps at /dev/ttyS2 how would i read from that.

    Do you have the datasheet for your GPS device on-hand, or perhaps a part number from which we could find a datasheet from? That would be the easiest way in which we could deduce the correct manner in which to communicate with the device!

    Also I believe that you want this
    $data = '';
            while($buffer = fread($stream, 30))//read from stream 
    	{
                $data = $buffer;
            }
    	$latlng = explode(";", $data);
    


    to be this
    $data = '';
            while($buffer = fread($stream, 30))//read from stream 
    	{
                $data .= $buffer;
            }
    	$latlng = explode(";", $data);
    


    Correct me if I'm wrong, but I believe that the $data variable in the first code box will be overwritten with each new iteration of $buffer rather than being appended to!
  2. In Topic: RAW HTML Code being displayed instead of actual content - Joomla!

    Posted 20 Jan 2012

    Righto - your HTML looks solid, which is why I was curious about a full email... Particularly the "Content-Type" header.

    One thing I've read about is that some code will use line-return characters in combination with, or instead of newline characters to concatenate email headers. Some email clients such as Gmail choke up if the headers weren't concatenated properly and will misinterpret the content type as a result.

    I dug a little further, and as long as you're setting $mode to anything other than boolean FALSE, then we can disregard the Joomla controller being responsible for this problem as the Joomla JMail class never even touches the headers, directly. It inherits from the PHPMailer class. So if $mode is boolean TRUE, then your problem may well lie with PHPMailer.

    PHPMailer is in and of itself a Google Code project, and while there are no issues listed specifically pertaining to your problem, one does mention consistent header anomalies.

    There exists the possibility that your email client is gagging on improperly formatted headers. I might suggest attempting to open the email in several different clients. But again, examining the actual headers that are being dispatched is probably a solid debugging step at this point.
  3. In Topic: Drop down menu, CSS problem

    Posted 20 Jan 2012

    I'm sorry, I've opened your link in Internet Explorer 8, Mozilla Firefox 4, and Google Chrome 16, and they all look pretty much identical to the picture from your laptop.

    - What browser are you using on your desktop?
    - Are you saying that the main navigation menu appears to be shifted to the right on your desktop?
  4. In Topic: How i can reverse this ? (PHP)

    Posted 20 Jan 2012

    Both of the above answers would work. The PHP implementation of Dormilich's solution would be something akin to
    <?php
    	$comments = (array) comments($page_id);
    	$comments = array_reverse( $comments, FALSE );
    
     	foreach ($comments as $comment) {
    
     ?>
         <div class="comment shadow effect">
             <p class="left tip">
                 <img class="avatar" src="<?php echo get_gravatar($comment['email'],40);?>" />
             </p>
             
             
             <p class="body right">
             <?php echo nl2br($comment['comment']);?>
             </p>
             
             
             
             <div class="detali_com">
             <div class="blue" style="width:50%; text-align:left; float: left; "><?php echo $comment['username'];?> Said</div>
             <div class="red"  style="width:50%; text-align:right; float: left;"><a href="#" onclick="$(this).delete_comment(<?php echo $comment['id'];?>); return false;"><span class="blue"><?php echo timeBetween($comment['time'],time());?></span> · Remove Comment</a></div>
             </div>
             </p>
             
         </div>
     <?php
     }
     ?>
    
    


    or, alternately choosing to omit the array_reverse funciton,
    <?php
    	$comments = (array) comments($page_id);
     	for ($i = count($comments) - 1; $i > 0; $i--) {
    
     ?>
         <div class="comment shadow effect">
             <p class="left tip">
                 <img class="avatar" src="<?php echo get_gravatar($comments[$i]['email'],40);?>" />
             </p>
             
             
             <p class="body right">
             <?php echo nl2br($comments[$i]['comment']);?>
             </p>
             
             
             
             <div class="detali_com">
             <div class="blue" style="width:50%; text-align:left; float: left; "><?php echo $comment['username'];?> Said</div>
             <div class="red"  style="width:50%; text-align:right; float: left;"><a href="#" onclick="$(this).delete_comment(<?php echo $comments[$id]['id'];?>); return false;"><span class="blue"><?php echo timeBetween($comments[$i]['time'],time());?></span> · Remove Comment</a></div>
             </div>
             </p>
             
         </div>
     <?php
     }
     ?>
    
    
  5. In Topic: How i can extract from database this...

    Posted 20 Jan 2012

    Expanding on that thought, you may also want to check out this StackOverflow post.

My Information

Member Title:
D.I.C Head
Age:
22 years old
Birthday:
November 18, 1990
Gender:
Location:
Lost on the face of some obscure mountain...
Years Programming:
7
Programming Languages:
C, C++, Java, JavaFX, PHP, Javascript, XHTML, SQL, TorqueScript

Contact Information

E-mail:
Private
Website URL:
Website URL  http://www.elementalsouls.com
Skype:
Skype  a.bosco1
Facebook:
http://facebook.com/adam.bosco
Twitter:
kurotsuto

Friends

KuroTsuto hasn't added any friends yet.

Comments

KuroTsuto has no profile comments yet. Why not say hello?