Activity Stream
48,167 MEMBERS
6871 ONLINE
besthostingforums On YouTube Subscribe to our Newsletter besthostingforums On Twitter besthostingforums On Facebook besthostingforums On facebook groups

Page 2 of 4 FirstFirst 1234 LastLast
Results 11 to 20 of 34

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1.     
    #1
    Member
    PHP Code: 
    $user = array(
        
    'dob' => 25121988,
        
    'age' => 21,
        
    'profile' => array(
            
    'username' => 'litewarez'
        
    )
    );

    var_dump$user['profile'] );

    var_dump$user[2] ); // DOES NOT WORK, WRONG! 
    Output:
    Code: 
    array(1) {
      ["username"]=>
      string(9) "litewarez"
    }
    
    NULL
    el_jentel1 Reviewed by el_jentel1 on . How would you translate this in PHP ? For first value in $var do something... I think it is subarray.. like - $entry_array .. So t3od0r how to choose the first or any other value.. And btw the values are actually all entries/pages of content. I think if($entry_array) works but if i want to do this --- if($entry_array){$entry_array=$entry_array.'TEST';} it adds 'TEST' to all entries not the first one...(maybe because the code like this means 'if exist'?) Rating: 5

  2.   Sponsored Links

  3.     
    #2
    Member
    You forgot your Post Code and your Mother's maiden name in that array, lite.

  4.     
    #3
    Member
    Website's:
    maxneeds.info
    Robin H it might so.. Do you want some real code from the page ???

    There you have it ..


    Code: 
    Array ( [subject] => The Eye (2008) DVDRip [date] => Wednesday, April 28, 2010, 10:17 [date_numeric_day] => 28 [date_numeric_month] => 4 [date_numeric_year] => '10 [date_alpha_month] => Apr [date_numeric_time] => 10:17 [date_suffix_day] => 28th [categories] => Array ( [0] => MKV ) [categories_id] => Array ( [0] => 73 ) [edit] => Array ( [name] => edit [url] => preview_cgi.php?y=10&m=04&entry=entry100428-101711 ) [delete] => Array ( [name] => delete [url] => delete.php?y=10&m=04&entry=entry100428-101711 ) [permalink] => Array ( [name] => permalink [url] => http://xxx.com ) [entry] =>ENTRY CONTENT)

  5.     
    #4
    Member
    Website's:
    litewarez.net litewarez.com triniwarez.com
    yes show some code lol
    Join Litewarez.net today and become apart of the community.
    Unique | Clean | Advanced (All with you in mind)
    Downloads | Webmasters


    Notifications,Forum,Chat,Community all at Litewarez Webmasters


  6.     
    #5
    Member
    Website's:
    maxneeds.info
    el_jentel1 thank you all but how do i add the word 'TEST' to the first multidimensional array ??? i tried
    Code: 
    if($entry_array[ 'entry' ][0]){$entry_array[ 'entry' ][0]=$entry_array[ 'entry' ][0].'TEST';}
    but doesn't seems to happen

  7.     
    #6
    Member
    How to suffix the string "TEST" to a single element or all elements in a nested array?

    PHP Code: 
    if( isset( $entry_array'entry' ][0] ) )
    {
        
    $entry_array'entry' ][0] .= 'TEST';
        echo 
    'Found and suffixed.';
    }
    else
    {
        echo 
    'Element not found.';


  8.     
    #7
    Member
    Website's:
    litewarez.net litewarez.com triniwarez.com
    PHP Code: 
    if(isset($entry_array) && is_array($entry_array['entry']))
    {
        
    print_r($entry_array['entry']); //Show the contents of it 
    }else
    {
        echo 
    'The 2nd dimension is not an array';

    use that and send me debugged output

    and my bad elj, looks like i got it wrong ahah
    Join Litewarez.net today and become apart of the community.
    Unique | Clean | Advanced (All with you in mind)
    Downloads | Webmasters


    Notifications,Forum,Chat,Community all at Litewarez Webmasters


  9.     
    #8
    Member
    Website's:
    maxneeds.info
    el_jentel1 - yes

  10.     
    #9
    Member
    Website's:
    maxneeds.info
    The 2nd dimension is not an arrayThe 2nd dimension is not an arrayThe 2nd dimension is not an arrayThe 2nd dimension is not an arrayThe 2nd dimension is not an array
    The 2nd dimension is not an arrayThe 2nd dimension is not an arrayThe 2nd dimension is not an arrayThe 2nd dimension is not an arrayThe 2nd dimension is not an array
    The 2nd dimension is not an arrayThe 2nd dimension is not an arrayThe 2nd dimension is not an arrayThe 2nd dimension is not an arrayThe 2nd dimension is not an array
    The 2nd dimension is not an arrayThe 2nd dimension is not an arrayThe 2nd dimension is not an arrayThe 2nd dimension is not an arrayThe 2nd dimension is not an array
    The 2nd dimension is not an arrayThe 2nd dimension is not an arrayThe 2nd dimension is not an arrayThe 2nd dimension is not an arrayThe 2nd dimension is not an array
    The 2nd dimension is not an arrayThe 2nd dimension is not an arrayThe 2nd dimension is not an arrayThe 2nd dimension is not an arrayThe 2nd dimension is not an array
    The 2nd dimension is not an arrayThe 2nd dimension is not an arrayThe 2nd dimension is not an arrayThe 2nd dimension is not an arrayThe 2nd dimension is not an array
    The 2nd dimension is not an arrayThe 2nd dimension is not an arrayThe 2nd dimension is not an arrayThe 2nd dimension is not an arrayThe 2nd dimension is not an array
    The 2nd dimension is not an arrayThe 2nd dimension is not an arrayThe 2nd dimension is not an arrayThe 2nd dimension is not an arrayThe 2nd dimension is not an array
    The 2nd dimension is not an arrayThe 2nd dimension is not an arrayThe 2nd dimension is not an arrayThe 2nd dimension is not an arrayThe 2nd dimension is not an array

  11.     
    #10
    Member
    Website's:
    litewarez.net litewarez.com triniwarez.com
    so then $entry_array['entry'] does not exists or is not an array, you cant do what your trying to do :/

    try

    $entry_array['entry'] .= 'Test';
    Join Litewarez.net today and become apart of the community.
    Unique | Clean | Advanced (All with you in mind)
    Downloads | Webmasters


    Notifications,Forum,Chat,Community all at Litewarez Webmasters


Page 2 of 4 FirstFirst 1234 LastLast

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Translate page
    By skinner in forum Web Development Area
    Replies: 1
    Last Post: 1st May 2012, 01:35 PM
  2. How to translate a template ?
    By Debaldus in forum DLE
    Replies: 9
    Last Post: 20th Feb 2012, 07:58 PM
  3. need translate script
    By peterpetroli in forum Web Development Area
    Replies: 5
    Last Post: 29th Dec 2011, 03:39 AM
  4. DLE translate tuto
    By milooot in forum Webmaster Discussion
    Replies: 3
    Last Post: 3rd Aug 2011, 05:23 PM
  5. Can someone translate this for me
    By kohkindachi in forum Technical Help Desk Support
    Replies: 2
    Last Post: 3rd Oct 2010, 01:34 PM

Tags for this Thread

BE SOCIAL