+ Reply to Thread
Results 1 to 10 of 10

Thread: direct output the exact value from database table

Hybrid View

  1. #1

    direct output the exact value from database table

    what line of code i have to add to output the exact value from database table filed , like we have a filed name category_id it contains values in numeric numbers but names in some other table
    if i write {$listing_data.Category_ID} it outputs value but not name , what i have to write to output the name of the category , there are some select fields also similar to this containing values but when i write {$listing_data.projects_types} it outputs numeric values but not exact name

    Please Help what line of code to add to echo exact value and not there respective ID's

  2. #2
    We are using "LEFT JOIN" and connecting with other tables and take keys.
    Example:
    Code:
    Only registered members can view the code.
    and you can get key of the categories. Then take category name from the key with the function 'replaceLangKeys'

    Code:
    Only registered members can view the code.
    Viktor,
    Flynax technical department,
    Best wishes.

  3. #3
    what code i have to had in tpl file to load correct data from any field as the data is being loaded on tpl file can you please tell me the exact code to add on listing_details.tpl file to load anything from fl_listing table with name but not there id's

  4. #4
    At first, I sugget you print 2 arrays on listing_details.tpl file:
    Code:
    Only registered members can view the code.
    maybe the information which you need already exists there.
    Viktor,
    Flynax technical department,
    Best wishes.

  5. #5
    Untitled.jpg
    These are the 6 values i need to pick on listing detail page how can i do that what line of code should i add ? remember the field name in database table is projects_types
    see screenshot for reference

  6. #6
    These are the 6 values i need to pick on listing detail page how can i do that what line of code should i add ? remember the field name in database table is projects_types
    see attached url to view photo clearly
    https://ibb.co/NmtnQmq

  7. #7
    click right mouse button and choose: View Page Source
    find the array and path to the value. approximate variable: {$listing.Fields.description_add.value}
    But as I see you need to learn how to work with the arrays. And I suggest you create a new ticket with the request and our tech support add value to view details page.
    Last edited by Viktor; July 30, 2019 at 06:19 AM.
    Viktor,
    Flynax technical department,
    Best wishes.

  8. #8
    Hello Viktor i have sufficient knowledge of arrays but just need little guidance ,
    if i get one right i will do it for others , right now i need to get these three values , country , country_level1 , country_level2 , Like they are in the screenshot , only the highlighted part i write {$listing_data.Fields.country_level1.value} on listing_detail page but cant display anything with it ,
    i cant open ticket for one thing as i need to add alot of things so i cant open ticket for each and every thing i need
    please help me with this last thing can you ??

    https://ibb.co/TLPQSSr

  9. #9
    ok, please print $listing array then click right button mouse and choose: View Page Source,
    Find the array from the code and find the country field. I hope it will help you to create the correct variable.
    Viktor,
    Flynax technical department,
    Best wishes.

  10. #10
    i got it thankyou so much viktor

+ Reply to Thread