
{"id":1345,"date":"2018-02-21T15:48:17","date_gmt":"2018-02-21T08:48:17","guid":{"rendered":"https:\/\/blog.travelpayouts.com\/en\/?p=1345"},"modified":"2021-10-02T20:51:30","modified_gmt":"2021-10-02T17:51:30","slug":"invitation-for-testing-a-new-widget","status":"publish","type":"post","link":"https:\/\/www.travelpayouts.com\/blog\/invitation-for-testing-a-new-widget\/","title":{"rendered":"Invitation for Testing a New Flight Ticket Widget for Specific Dates"},"content":{"rendered":"<h2>How to Use the New Widget<\/h2>\n<p>The widget allows you to display a block with prices in a predefined destination for specific dates on your site. The departure airport is automatically filled from the user&#8217;s location by default, but the user has the option to change the departure airport manually in the widget.<\/p>\n<p>An example of the code for displaying the tool on a page:<\/p>\n<div style=\"background: #f0f0f0;overflow: auto;width: auto;border: solid gray;border-width: .1em .1em .1em .8em;padding: .2em .6em\">\n<pre style=\"margin: 0;line-height: 125%\"><span style=\"color: #062873;font-weight: bold\">&lt;div<\/span> <span style=\"color: #4070a0\">id=\"test\"<\/span><span style=\"color: #062873;font-weight: bold\">&gt;<\/span>\n\n<span style=\"color: #062873;font-weight: bold\">&lt;\/div&gt;<\/span>\n\n<span style=\"color: #062873;font-weight: bold\">&lt;script <\/span><span style=\"color: #4070a0\">src=\"https:\/\/cdnjs.cloudflare.com\/ajax\/libs\/jquery\/3.3.1\/jquery.min.js\"<\/span><span style=\"color: #062873;font-weight: bold\">&gt;&lt;\/script&gt;<\/span>\n\n<span style=\"color: #062873;font-weight: bold\">&lt;script <\/span><span style=\"color: #4070a0\">src=\"\/\/misc.travelpayouts.com\/khl2017\/script.php?lang=en&amp;marker=66886&amp;container=test&amp;destination=MOW&amp;flights=2018-03-27:2018-03-29|2018-04-15:2018-04-18|2018-05-01:2018-05-07\"<\/span><span style=\"color: #062873;font-weight: bold\">&gt;&lt;\/script&gt;<\/span>\n<\/pre>\n<\/div>\n<p>Now, the widget does not have features for a quick creation in the personal account while the rest of our tools have. However, you can already use all functions manually today. For this, follow the instructions below.<\/p>\n<ol>\n<li>Add an element where it is necessary to display the widget and add to this element any arbitrary ID, for example:<\/li>\n<\/ol>\n<div style=\"background: #f0f0f0;overflow: auto;width: auto;border: solid gray;border-width: .1em .1em .1em .8em;padding: .2em .6em\">\n<pre style=\"margin: 0;line-height: 125%\"><span style=\"color: #062873;font-weight: bold\">&lt;div<\/span> <span style=\"color: #4070a0\">id=\"test\"<\/span> <span style=\"color: #062873;font-weight: bold\">&gt;&lt;\/div&gt;<\/span>\n<\/pre>\n<\/div>\n<ol start=\"2\">\n<li>Next, you need to connect the Jquery library. If you have not done it before on your page, to do this, use this code:<\/li>\n<\/ol>\n<div style=\"background: #f0f0f0;overflow: auto;width: auto;border: solid gray;border-width: .1em .1em .1em .8em;padding: .2em .6em\">\n<pre style=\"margin: 0;line-height: 125%\"><span style=\"color: #062873;font-weight: bold\">&lt;script <\/span><span style=\"color: #4070a0\">src=\"https:\/\/cdnjs.cloudflare.com\/ajax\/libs\/jquery\/3.3.1\/jquery.min.js\"<\/span><span style=\"color: #062873;font-weight: bold\">&gt;&lt;\/script&gt;<\/span>\n<\/pre>\n<\/div>\n<ol start=\"3\">\n<li>After connecting JQuery, specify the path to the widget. In this part are written the main parameters for working. For example:<\/li>\n<\/ol>\n<div style=\"background: #f0f0f0;overflow: auto;width: auto;border: solid gray;border-width: .1em .1em .1em .8em;padding: .2em .6em\">\n<pre style=\"margin: 0;line-height: 125%\"><span style=\"color: #062873;font-weight: bold\">&lt;script <\/span><span style=\"color: #4070a0\">src=\"https:\/\/misc.travelpayouts.com\/khl2017\/script.php?lang=en&amp;marker=66886&amp;container=test&amp;destination=TSE&amp;flights=2018-01-09:2018-01-15|2018-01-10:2018-01-14|2018-01-12:2018-01-14|2018-01-12:2018-01-15\"<\/span><span style=\"color: #062873;font-weight: bold\">&gt;&lt;\/script&gt;<\/span>\n<\/pre>\n<\/div>\n<p>Parameters to work with the widget:<\/p>\n<ul>\n<li>lang \u2014 the language of the widget (in the example above: en, you can change to Russian: ru);<\/li>\n<li>marker \u2014 your marker (6 digits, look at your account);<\/li>\n<li>container \u2014 the container for the widget (see above, for example, \u201ctest\u201d or another name you chose);<\/li>\n<li>destination \u2014 the city of destination (for example TSE &#8211; Astana, LAX &#8211; Los Angeles, three letters);<\/li>\n<li>flights \u2014 an array with the required flight dates;<\/li>\n<\/ul>\n<h2>Working With the Flights Field<\/h2>\n<p>Let&#8217;s imagine that you want to set 2 flights:<\/p>\n<ul>\n<li>From December 21, 2018, to December 28, 2018<\/li>\n<li>From December 18, 2018, to December 22, 2018<\/li>\n<\/ul>\n<p>In this case, the flight will have the value:<\/p>\n<div style=\"background: #f0f0f0;overflow: auto;width: auto;border: solid gray;border-width: .1em .1em .1em .8em;padding: .2em .6em\">\n<pre style=\"margin: 0;line-height: 125%\">flights=2018-12-21:2017-12-28|2018-12-18:2017-12-22<\/pre>\n<\/div>\n<p>To form the block, the symbols \u2018:\u2019 and \u2018|\u2019 are used:<\/p>\n<ul>\n<li>Each date (to\/from) will be separated by the symbol &#8220;:&#8221;.<\/li>\n<li>Each flight, which has the flight for both sides, is divided by the symbol &#8220;|&#8221;.<\/li>\n<\/ul>\n<p>This tool will perfectly fit into the materials about the forthcoming World Cup 2018. You can make an offer for each game through this new widget because the dates are already known. Regional hotels have ridden prices that some fans are searching seriously for the options of living in Moscow and flying for selected matches to other cities. <a href=\"https:\/\/travelpayouts.com\/blog\/world-cup\/\">Recently we considered other options<\/a> about how you could earn on World Cup 2018 with Travelpayouts tools \u2014 don\u2019t miss this chance.<\/p>\n<p>The tool is suitable for other events \u2014 large industry conferences, holidays (St. Valentine\u2019s Day, International Women&#8217;s Day, etc.), the beginning of the holiday season and any other that is associated with specific dates.<\/p>\n<p>Ekaterina Rakova from Booking.com recommended <a href=\"https:\/\/travelpayouts.com\/blog\/travelpayouts-affiliate-summit-2017\/\">on the Travelpayouts Affiliate Summit<\/a> for all partners to fill the forms in advance. This reduces the amount of actions required from the user, which increase the conversion rate in theory. The new flight widget has an offer for specific dates, what fit for this logic.<\/p>\n<p>Try it yourself, and share with us your achievement, ideas, and even critiques. We upload the tool in advance in alpha stage to have a chance to make the final product better for you.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>We want to please you with a new flight ticket widget for specific dates and invite you to test our new tool. Let&#8217;s make the tool better! It is already possible to install and try it today, but it works only in manual mode. We are waiting for your feedback and ideas. Warning: this is the alpha version \u2014 full performance is not guaranteed.<\/p>\n","protected":false},"author":3,"featured_media":1348,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"_eb_attr":"","footnotes":""},"categories":[5],"tags":[],"class_list":["post-1345","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-news"],"acf":[],"amp_enabled":true,"_links":{"self":[{"href":"https:\/\/www.travelpayouts.com\/blog\/wp-json\/wp\/v2\/posts\/1345","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.travelpayouts.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.travelpayouts.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.travelpayouts.com\/blog\/wp-json\/wp\/v2\/users\/3"}],"replies":[{"embeddable":true,"href":"https:\/\/www.travelpayouts.com\/blog\/wp-json\/wp\/v2\/comments?post=1345"}],"version-history":[{"count":4,"href":"https:\/\/www.travelpayouts.com\/blog\/wp-json\/wp\/v2\/posts\/1345\/revisions"}],"predecessor-version":[{"id":6887,"href":"https:\/\/www.travelpayouts.com\/blog\/wp-json\/wp\/v2\/posts\/1345\/revisions\/6887"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.travelpayouts.com\/blog\/wp-json\/wp\/v2\/media\/1348"}],"wp:attachment":[{"href":"https:\/\/www.travelpayouts.com\/blog\/wp-json\/wp\/v2\/media?parent=1345"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.travelpayouts.com\/blog\/wp-json\/wp\/v2\/categories?post=1345"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.travelpayouts.com\/blog\/wp-json\/wp\/v2\/tags?post=1345"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}