[campsite-support] print Article images in campsite 3.1
  • hi

    i need to print article image 1 if exists beside article title , i looked
    for new manual but i did't find clear example

    i try to use

    {{ if $article->image_number == "1" }}

    ---

    {{else}}
    ----

    how can i print the image inside the above if statment


    any help?

    best regards





    --
    Alaa Anabtawi
  • 7 Comments sorted by
  • see "has_image()" in
    http://code.campware.org/manuals/campsite/3.1/index.php?id=179


    On Tue, Jul 29, 2008 at 11:46 AM, Alaa Anabtawi wrote:

    > hi
    >
    > i need to print article image 1 if exists beside article title , i looked
    > for new manual but i did't find clear example
    >
    > i try to use
    >
    > {{ if $article->image_number == "1" }}
    >
    > ---
    >
    > {{else}}
    > ----
    >
    > how can i print the image inside the above if statment
    >
    >
    > any help?
    >
    > best regards
    >
    >
    >
    >
    >
    > --
    > Alaa Anabtawi
    >
  • thank

    i tried with no sucsess

    also i tried this {{ $campsite->article->image(1) }} with no sucsses

    can one send me what excatly code should i use

    best regards




    On 7/29/08, Mugur Rus wrote:
    >
    > see "has_image()" in
    > http://code.campware.org/manuals/campsite/3.1/index.php?id=179
    >
    >
    > On Tue, Jul 29, 2008 at 11:46 AM, Alaa Anabtawi wrote:
    >
    >> hi
    >>
    >> i need to print article image 1 if exists beside article title , i looked
    >> for new manual but i did't find clear example
    >>
    >> i try to use
    >>
    >> {{ if $article->image_number == "1" }}
    >>
    >> ---
    >>
    >> {{else}}
    >> ----
    >>
    >> how can i print the image inside the above if statment
    >>
    >>
    >> any help?
    >>
    >> best regards
    >>
    >>
    >>
    >>
    >>
    >> --
    >> Alaa Anabtawi
    >>
    >
    >
    >



    --
    Alaa Anabtawi
  • There is a manual up there, if you took the time to read the page I pointed
    you too you could find the following properties:
    - has_image()
    - image

    The code is:
    {{ if $campsite->article->has_image(1) }}
    {{ $campsite->article->image1->description }}
    {{ /if }}

    On Tue, Jul 29, 2008 at 1:45 PM, Alaa Anabtawi wrote:

    > thank
    >
    > i tried with no sucsess
    >
    > also i tried this {{ $campsite->article->image(1) }} with no sucsses
    >
    > can one send me what excatly code should i use
    >
    > best regards
    >
    >
    >
    >
    > On 7/29/08, Mugur Rus wrote:
    >>
    >> see "has_image()" in
    >> http://code.campware.org/manuals/campsite/3.1/index.php?id=179
    >>
    >>
    >> On Tue, Jul 29, 2008 at 11:46 AM, Alaa Anabtawi wrote:
    >>
    >>> hi
    >>>
    >>> i need to print article image 1 if exists beside article title , i
    >>> looked for new manual but i did't find clear example
    >>>
    >>> i try to use
    >>>
    >>> {{ if $article->image_number == "1" }}
    >>>
    >>> ---
    >>>
    >>> {{else}}
    >>> ----
    >>>
    >>> how can i print the image inside the above if statment
    >>>
    >>>
    >>> any help?
    >>>
    >>> best regards
    >>>
    >>>
    >>>
    >>>
    >>>
    >>> --
    >>> Alaa Anabtawi
    >>>
    >>
    >>
    >>
    >
    >
    >
    > --
    > Alaa Anabtawi
  • in simple word's

    what is the new syntax of this






    best regards

    thanks

    On 7/29/08, Alaa Anabtawi wrote:
    >
    > thank
    >
    > i tried with no sucsess
    >
    > also i tried this {{ $campsite->article->image(1) }} with no sucsses
    >
    > can one send me what excatly code should i use
    >
    > best regards
    >
    >
    >
    >
    > On 7/29/08, Mugur Rus wrote:
    >>
    >> see "has_image()" in
    >> http://code.campware.org/manuals/campsite/3.1/index.php?id=179
    >>
    >>
    >> On Tue, Jul 29, 2008 at 11:46 AM, Alaa Anabtawi wrote:
    >>
    >>> hi
    >>>
    >>> i need to print article image 1 if exists beside article title , i
    >>> looked for new manual but i did't find clear example
    >>>
    >>> i try to use
    >>>
    >>> {{ if $article->image_number == "1" }}
    >>>
    >>> ---
    >>>
    >>> {{else}}
    >>> ----
    >>>
    >>> how can i print the image inside the above if statment
    >>>
    >>>
    >>> any help?
    >>>
    >>> best regards
    >>>
    >>>
    >>>
    >>>
    >>>
    >>> --
    >>> Alaa Anabtawi
    >>>
    >>
    >>
    >>
    >
    >
    >
    > --
    > Alaa Anabtawi




    --
    Alaa Anabtawi
  • thanks very much for you help , but this code also does not work

    the if statment are working well, but the image did not apeeared

    here is the code that am using




    {{ local }}
    {{ set_language name="Arabic" }}
    {{ set_issue number="1" }}
    {{ set_section number="1" }}
    {{ list_articles length="5" }}



    {{ if $campsite->article->has_image(1) }}

    {{ /if }}
      style="font-size: 9pt" color="#FFFFFF">{{
    $campsite->article->title_text }} -  style="font-size: 9pt" color="#666666">{{ $campsite->article->author
    }}





    {{ /list_articles }}
    {{ /local}}


    also i tryed to put the path before ="{{
    $campsite->article->image1->description }}" with no sucsess
    any more hints


    On 7/29/08, Mugur Rus wrote:
    >
    > There is a manual up there, if you took the time to read the page I pointed
    > you too you could find the following properties:
    > - has_image()
    > - image
    >
    > The code is:
    > {{ if $campsite->article->has_image(1) }}
    > {{ $campsite->article->image1->description }}
    > {{ /if }}
    >
    > On Tue, Jul 29, 2008 at 1:45 PM, Alaa Anabtawi wrote:
    >
    >> thank
    >>
    >> i tried with no sucsess
    >>
    >> also i tried this {{ $campsite->article->image(1) }} with no sucsses
    >>
    >> can one send me what excatly code should i use
    >>
    >> best regards
    >>
    >>
    >>
    >>
    >> On 7/29/08, Mugur Rus wrote:
    >>>
    >>> see "has_image()" in
    >>> http://code.campware.org/manuals/campsite/3.1/index.php?id=179
    >>>
    >>>
    >>> On Tue, Jul 29, 2008 at 11:46 AM, Alaa Anabtawi wrote:
    >>>
    >>>> hi
    >>>>
    >>>> i need to print article image 1 if exists beside article title , i
    >>>> looked for new manual but i did't find clear example
    >>>>
    >>>> i try to use
    >>>>
    >>>> {{ if $article->image_number == "1" }}
    >>>>
    >>>> ---
    >>>>
    >>>> {{else}}
    >>>> ----
    >>>>
    >>>> how can i print the image inside the above if statment
    >>>>
    >>>>
    >>>> any help?
    >>>>
    >>>> best regards
    >>>>
    >>>>
    >>>>
    >>>>
    >>>>
    >>>> --
    >>>> Alaa Anabtawi
    >>>>
    >>>
    >>>
    >>>
    >>
    >>
    >>
    >>
    >> --
    >> Alaa Anabtawi
    >
    >
    >


    --
    Alaa Anabtawi
  • This was just an example on how to use the image object. The field
    'description' does not return the image URL, but it returns the text you
    input in the description field.



    see also:
    http://code.campware.org/manuals/campsite/3.1/index.php?id=181
    http://code.campware.org/manuals/campsite/3.1/index.php?id=98


    On Tue, Jul 29, 2008 at 2:35 PM, Alaa Anabtawi wrote:

    > thanks very much for you help , but this code also does not work
    >
    > the if statment are working well, but the image did not apeeared
    >
    > here is the code that am using
    >
    >
    >
    >
    > {{ local }}
    > {{ set_language name="Arabic" }}
    > {{ set_issue number="1" }}
    > {{ set_section number="1" }}
    > {{ list_articles length="5" }}
    >
    >
    >
    > {{ if $campsite->article->has_image(1) }}
    >
    > {{ /if }}
    >  face="Tahoma" style="font-size: 9pt" color="#FFFFFF">{{
    > $campsite->article->title_text }} -  > style="font-size: 9pt" color="#666666">{{ $campsite->article->author
    > }}



    >
    >
    > {{ /list_articles }}
    > {{ /local}}
    >
    >
    > also i tryed to put the path before ="{{
    > $campsite->article->image1->description }}" with no sucsess
    > any more hints
    >
    >
    > On 7/29/08, Mugur Rus wrote:
    >>
    >> There is a manual up there, if you took the time to read the page I
    >> pointed you too you could find the following properties:
    >> - has_image()
    >> - image
    >>
    >> The code is:
    >> {{ if $campsite->article->has_image(1) }}
    >> {{ $campsite->article->image1->description }}
    >> {{ /if }}
    >>
    >> On Tue, Jul 29, 2008 at 1:45 PM, Alaa Anabtawi wrote:
    >>
    >>> thank
    >>>
    >>> i tried with no sucsess
    >>>
    >>> also i tried this {{ $campsite->article->image(1) }} with no sucsses
    >>>
    >>> can one send me what excatly code should i use
    >>>
    >>> best regards
    >>>
    >>>
    >>>
    >>>
    >>> On 7/29/08, Mugur Rus wrote:
    >>>>
    >>>> see "has_image()" in
    >>>> http://code.campware.org/manuals/campsite/3.1/index.php?id=179
    >>>>
    >>>>
    >>>> On Tue, Jul 29, 2008 at 11:46 AM, Alaa Anabtawi wrote:
    >>>>
    >>>>> hi
    >>>>>
    >>>>> i need to print article image 1 if exists beside article title , i
    >>>>> looked for new manual but i did't find clear example
    >>>>>
    >>>>> i try to use
    >>>>>
    >>>>> {{ if $article->image_number == "1" }}
    >>>>>
    >>>>> ---
    >>>>>
    >>>>> {{else}}
    >>>>> ----
    >>>>>
    >>>>> how can i print the image inside the above if statment
    >>>>>
    >>>>>
    >>>>> any help?
    >>>>>
    >>>>> best regards
    >>>>>
    >>>>>
    >>>>>
    >>>>>
    >>>>>
    >>>>> --
    >>>>> Alaa Anabtawi
    >>>>>
    >>>>
    >>>>
    >>>>
    >>>
    >>>
    >>>
    >>>
    >>> --
    >>> Alaa Anabtawi
    >>
    >>
    >>
    >
    >
    > --
    > Alaa Anabtawi
  • thanks very much this what i need

    it's worked

    thanks



    On 7/29/08, Mugur Rus wrote:
    >
    > This was just an example on how to use the image object. The field
    > 'description' does not return the image URL, but it returns the text you
    > input in the description field.
    >
    >
    >
    > see also:
    > http://code.campware.org/manuals/campsite/3.1/index.php?id=181
    > http://code.campware.org/manuals/campsite/3.1/index.php?id=98
    >
    >
    > On Tue, Jul 29, 2008 at 2:35 PM, Alaa Anabtawi wrote:
    >
    >> thanks very much for you help , but this code also does not work
    >>
    >> the if statment are working well, but the image did not apeeared
    >>
    >> here is the code that am using
    >>
    >>
    >>
    >>
    >> {{ local }}
    >> {{ set_language name="Arabic" }}
    >> {{ set_issue number="1" }}
    >> {{ set_section number="1" }}
    >> {{ list_articles length="5" }}
    >>
    >>
    >>
    >> {{ if $campsite->article->has_image(1) }}
    >>
    >>
    >> {{ /if }}
    >>  face="Tahoma" style="font-size: 9pt" color="#FFFFFF">{{
    >> $campsite->article->title_text }} -  >> style="font-size: 9pt" color="#666666">{{ $campsite->article->author
    >> }}



    >>
    >>
    >> {{ /list_articles }}
    >> {{ /local}}
    >>
    >>
    >> also i tryed to put the path before ="{{
    >> $campsite->article->image1->description }}" with no sucsess
    >> any more hints
    >>
    >>
    >> On 7/29/08, Mugur Rus wrote:
    >>>
    >>> There is a manual up there, if you took the time to read the page I
    >>> pointed you too you could find the following properties:
    >>> - has_image()
    >>> - image
    >>>
    >>> The code is:
    >>> {{ if $campsite->article->has_image(1) }}
    >>> {{ $campsite->article->image1->description }}
    >>> {{ /if }}
    >>>
    >>> On Tue, Jul 29, 2008 at 1:45 PM, Alaa Anabtawi wrote:
    >>>
    >>>> thank
    >>>>
    >>>> i tried with no sucsess
    >>>>
    >>>> also i tried this {{ $campsite->article->image(1) }} with no sucsses
    >>>>
    >>>> can one send me what excatly code should i use
    >>>>
    >>>> best regards
    >>>>
    >>>>
    >>>>
    >>>>
    >>>> On 7/29/08, Mugur Rus wrote:
    >>>>>
    >>>>> see "has_image()" in
    >>>>> http://code.campware.org/manuals/campsite/3.1/index.php?id=179
    >>>>>
    >>>>>
    >>>>> On Tue, Jul 29, 2008 at 11:46 AM, Alaa Anabtawi wrote:
    >>>>>
    >>>>>> hi
    >>>>>>
    >>>>>> i need to print article image 1 if exists beside article title , i
    >>>>>> looked for new manual but i did't find clear example
    >>>>>>
    >>>>>> i try to use
    >>>>>>
    >>>>>> {{ if $article->image_number == "1" }}
    >>>>>>
    >>>>>> ---
    >>>>>>
    >>>>>> {{else}}
    >>>>>> ----
    >>>>>>
    >>>>>> how can i print the image inside the above if statment
    >>>>>>
    >>>>>>
    >>>>>> any help?
    >>>>>>
    >>>>>> best regards
    >>>>>>
    >>>>>>
    >>>>>>
    >>>>>>
    >>>>>>
    >>>>>> --
    >>>>>> Alaa Anabtawi
    >>>>>>
    >>>>>
    >>>>>
    >>>>>
    >>>>
    >>>>
    >>>>
    >>>>
    >>>> --
    >>>> Alaa Anabtawi
    >>>
    >>>
    >>>
    >>
    >>
    >>
    >> --
    >> Alaa Anabtawi
    >
    >
    >


    --
    Alaa Anabtawi