Re: [Cppcms-users] How to link external URL with CppCMS?
Brought to you by:
artyom-beilis
From: Asog <ret...@gm...> - 2018-09-20 16:06:59
|
This works too, but not sure about neatness: response().out() << "<a href='" << "https://www.google.com" << "'>Google</a><br>"; On Thu, Sep 20, 2018 at 10:59 PM Nazim Can Bedir <naz...@ne...> wrote: > Hi, > > You forgot that you are writing code in C++, so you need to start and end > string literal with " (double quote), and escape the inner quotes. > > response().out() << "<a href=\"https://www.google.com\">Google</a>"; > > Regards, > Nazim Can. > > -- > С уважением, > Назым-Джан Бэдир > > 18:24, 20 September 2018, "hoang nguyen via Cppcms-users" < > cpp...@li...>: > > Nazim, > I tried the following code as you said and it failed: > > response().out() << <a href="https://www.google.com">Google</a>; > > What am I missing? > -------------------------------------------- > On Thu, 9/20/18, Nazim Can Bedir <naz...@ne...> wrote: > > Subject: Re: [Cppcms-users] How to link external URL with CppCMS? > To: "cpp...@li..." < > cpp...@li...> > Date: Thursday, September 20, 2018, 5:07 PM > > Hello, > 'url' template command is > used to output address of url_mapper routes. If you want to > create link for an external URL, you just need to use usual > HTML; i.e. > <a > href="https://www.google.com">Google</a> > Regards,Nazim Can. > > -- > С > уважением, > Назым-Джан > Бэдир > > 12:45, 20 > September 2018, Asog > <ret...@gm...>: > > > Hello, > I got my CppCMS page > working following this > tutorial > (full > code). However, it > doesn't show how to link to an outside URL (i.e., > www.google.com). > Can someone point out to me how it can be done? TIA. > > > > _______________________________________________ > Cppcms-users mailing list > Cpp...@li... > https://lists.sourceforge.net/lists/listinfo/cppcms-users > > > _______________________________________________ > Cppcms-users mailing list > Cpp...@li... > https://lists.sourceforge.net/lists/listinfo/cppcms-users > > -----Inline Attachment Follows----- > > > -----Inline Attachment Follows----- > > > > > _______________________________________________ > Cppcms-users mailing list > Cpp...@li... > https://lists.sourceforge.net/lists/listinfo/cppcms-users > > _______________________________________________ > Cppcms-users mailing list > Cpp...@li... > https://lists.sourceforge.net/lists/listinfo/cppcms-users > |