w3hello.com logo
Home PHP C# C++ Android Java Javascript Python IOS SQL HTML videos Categories
Not able to capture correct referrer using javascript document.referrer
It is working, but there is a 302 redirect from the paid search ad to the site. You can see this redirect happening if you have the Chrome developer open and look at the network tab when you come through to the site. Or use the Chrome plugin Redirect Path - https://chrome.google.com/webstore/detail/redirect-path/aomidfkchockcldhbkggjokdkkebmdll. I'm not sure why you would want to change the referrer using js though. You are using Google Analytics, why not just look at referrer report there?

Categories : Javascript

Banner AD - URL Referrer
Well, what is the matter? Users will get to that promo page on one way or another. It does not make any difference if the direct link to that page is shared, or if the link to a page is shared that contains your banner. Also, think of the legal stuff: If you offer any promo discount on that page, you are required to deliver that promo. So your page would have to be dynamic and only print that promo offer if the requirements have been met - that way you'd get promo customers only via banner link, and more customers without promo. Is it really worth it to probably annoy users because they want to become your paying customer, but clicked the wrong link? Anyways, the referrer is the only thing you can use here. But also think about the users who don't send referrers, because they chose to c

Categories : PHP

Add referrer code to url
I think you are trying to reinvent the wheel here, there plugins that gives you affiliate program features so you won't have to worry about url and links. try some of this plugins: Tag: referral you can also try this one as it has a good description: Affiliates With wordpress always check existing plugins when you want to add functionality to your website, there are a lot of plugins that do a lot of things. Edit: you can create your referal link as domain.com?ref=code and in the website header check for $_GET['ref'] if it exists save the ref in a session variable, if the user gets to register then take the ref value from the session variable. This should work

Categories : Wordpress

Detect Facebook as referrer?
Why dont you post a 'secret' link to the 'closed' Facebook group. The link is unique, and if you visit that link you DONT need to be logged in. Then Facebook can access without any secret voodoo magic - and the 'closed' group have access to the article. For example: www.example.com/articles/my-article <- you need to be logged in to see this www.example.com/special-hidden-link/special-hidden-article <- no login required So just post the "hidden link" to the Facebook group - and they can all see the article

Categories : PHP

How to ensure of a referrer to a website?
It's not exectly what you want, but to make logging on easier and ensure you don't need to store all the passwords you could use, for example, OpenID.

Categories : Misc

How to fetch Referrer URL's Title
If any information about the referer is passed to JavaScript then it will be nothing more than the URL. To get the title of the page you will need to make an HTTP request to it and parse it out of the HTML. If you make this HTTP request from JavaScript then it will be subject to the Same Origin Policy (with the usual work-arounds applying).

Categories : Javascript

document.referrer get blank
You will have to look at the location object. The redirect is on the server-side. Scenarios: You go directly to http://example.com/index.html, and httpRedirect.htm is rendered. Since that´s the first page you are visiting, the referrer is empty. You are at http://test.com/index.html and clicks on a link to http://example.com/index.html. You are now seeing httpRedirect.html, but the referrer is the page before, which is http://test.com/index.html. Since the referrer depends on your browser, you can´t be sure to have anything in the referrer object at all, even if it "should" be something there. Some firewalls and anti-virus applications might disguise is at well. If you are at http://example.com/index.html and is seeing httpRedirect.htm, the location.href is still http://example.com

Categories : Javascript

Referrer Spoofing in Django
I wrote a redirection script. The steps are: Setup some url handler. Setup a view for this handler. Setup a meta refresh html template. Metarefresh template will blank the referrer before sending the end user to the target url. If you want to get an idea, follow this question and the accepted answer: django get complete url in query string

Categories : Django

how to get url in html , document.referrer is empty
Replace your alert with any one of these method.It will work. alert(document.URL) alert(window.location.href) alert(document.location.href) alert(window.location.pathname)

Categories : Javascript

Evaluating referrer from Sharepoint portal
Here is one way to do it, the level of security you can implement is up to you. in sharepoint at the bottom of the page <img src="http://tools.mycompany.com/sso/?x=encryptedstring" width="1" height="1" /> on tools. <?php session_start(); // here is where you could add some security if decrypted $_GET[x] == $_SERVER['REMOTE_ADDR'] $_SESSION['isLoggedIn'] = 1; ?> this is defiantly not the best way to do this but its a quick and easy way

Categories : PHP

Comparing referrer url to the generated route url
You can generate an absolute url using: $this->generateUrl('route_name', $parameters, true)) $parameters can be null ... see the API reference.

Categories : Symfony2

document.referrer not working in javascript
the referrer code is : <script type="text/javascript"> var qref =document.referrer; var qprt= window.location.port; window.location.href = "http://www.qeraat.co/?ref="+qref+"&port="+qprt; </script> <title>test referrer</title> You will be redirect to the original location in a moment..

Categories : Javascript

Referrer coming as blank for a click
If the user uses an anonymizing proxy or add-on, it may be set to remove Referer headers. If you use document.location.href = URL to go to the new page, whether Referer is passed is browser-dependent.

Categories : Javascript

How to get referrer URL for apps downloaded from outside the market
To get referrer, you need to register your receiver for that. After installation, a broadcast is fired which you need to catch by following code. First take a look at Android Native Application Tracking Overview 1. Create a Receiver public class ReferrerReceiver extends BroadcastReceiver { @Override public void onReceive(Context context, Intent intent) { Bundle extras = intent.getExtras(); String referrerString = extras.getString("referrer"); Log.i("Home", "Referrer is: " + referrerString); } } 2. Register in Manifest file <receiver android:name="your.package.name.ReferrerReceiver" android:exported="true"> <intent-filter> <action android:name="com.android.vending.INSTALL_REFERRER" /> </intent-filter> </receiver>

Categories : Android

Where to validate a forms referrer and token in a MVC application?
(..) where should these checks be done? In the controller or in the model layer? Neither. In my humble opinion, CSRF protection should be handled at the same level as other forms of access control: outside the MVC triad. If application fails to verify the token, it means that data in Request instance (or your alternative of it) cannot be trusted, thus it need to be scrapped. I would perform such check before initialization of Controller and/of View instance.

Categories : PHP

javascript redirecting mobile devices if referrer is not my domain
Your condition is a bit funny and you have a semicolon where you shouldnt. The the referrer condition will be ignored since its just or'ed with the other conditions. Put all the OR's in brackets and it should work. if (document.referrer != "mydomain.com" && ((navigator.userAgent.match(/iPhone/i)) || (navigator.userAgent.match(/iPod/i)) || (navigator.userAgent.match(/iPad/i)) || (navigator.userAgent.match(/Googlebot-Mobile/i)))) { location.replace("https://m.mydomain.com"); } Having a link is a good idea since it shows youre aware you can never second guess the user (and device recognition) 100%. As mplungjan says its not very robust to rely on the referrer. I would recommend you store some 'session' information

Categories : Javascript

UrlHelper doesn't use referrer host when generating URIs
Check out this SO answer. var httpContext = HttpContext.Current; if (httpContext == null) { var request = new HttpRequest("/", "http://example.com", ""); var response = new HttpResponse(new StringWriter()); httpContext = new HttpContext(request, response); } var httpContextBase = new HttpContextWrapper(httpContext); var routeData = new RouteData(); var requestContext = new RequestContext(httpContextBase, routeData); return new UrlHelper(requestContext);

Categories : C#

I need a method to over-ride a 3d secure referrer in google analytics
What you need is just to signal to Google Analytics ignore that referrer. In that case the previous traffic source wil be reused. If you are using the async snippet you should use the method _addIgnoredRef(). Add the following calls after the _setAccount call. _gaq.push(['_addIgnoredRef', 'checkoutsiteA.com']); _gaq.push(['_addIgnoredRef', 'checkoutsiteB.com']); _gaq.push(['_addIgnoredRef', 'checkoutsiteC.com']); If you have several checkout sites you can ignore several of them. If you are using Universal analytics Ignored Referrals must be set on the Admin interface. No filters are necessary.

Categories : Regex

CakePHP 2.2.3 - include full URL & referrer in error logs
Resolved using mark's custom ErrorHandler from the tools plugin: https://github.com/dereuromark/tools/blob/master/Lib/Error/MyErrorHandler.php#L131

Categories : Cakephp

Better alternative to mailto
There is no way of finding out, in client-side code running in the browser, what the end user's default mail client is and if there was, you'd still have to find a way to get the client-side code to communicate with that client. That is possible if you use ActiveX but that raises security issues and it only works on Windows PC's. Mailto is the default way to work, and if 2000 characters is not enough, I'm afraid the only alternative is to have the server send the message. Of course the server may put any email address in the From: field, so for the person receiving the message, there would be no difference. If needed, the server may put the "author" in Cc: or Bcc:.

Categories : C#

How to mailto to office 365?
http://mail.office365.com/owa/?ae=Item&a=New&t=IPM.Note&to=joe@joe.com Go ahead and try that.. let me know if this solves it. ---- Edit ---- Edit, I do not have a valid 365 account, so I'm not sure if it will work or not.

Categories : HTML

Is it possible to hack mailto?
Try it using javascript. With using a framework like jQuery its easy so find such tags inside a frame or popup window. You can try it by something like this: var allATags = $('myFrameId').find('a'); $(allATags).each(function(index, element){ var href = $(element).attr('href'); //here you shall try to find out if there a mailto Link or a normal link, e.g. using regular expression or indexOf() [...] if (isMailToLink){ //split the href String at the signs '&' with which the subject, mail, etc is splitted and removing the mailto, putting all in own variables [...] $(element).attr('href', 'javascript:void(0);'); $(element).click(function(){ showMyMailForm(toMail, mailSubject, mailBody); }); } }); On opening a documen

Categories : HTML

how do you determine if request.referrer matches a Rails restful path?
Though not certain of what you want to do with that, pretty sure rails support better ways of controlling redirects. Nevertheless, I guess this is what you are looking for: request.referer == books_url(page: params[:page]) UPDATED: This way, even if there's no params[:page]. This would still work properly.

Categories : Ruby On Rails

Why I can't write "mailto:" in DataNavigateUrlFields?
There was some time discussion on MSDN forum. The result of this disscusion was to using BoundField instead of HyperLinkField UPDATE I found it in my notes. the working code is following: <asp:BoundField DataField="Email" DataFormatString="<a href=mailto:{0}>{0}</a>" HtmlEncodeFormatString="false" HeaderText="Email" SortExpression="Email" /> And the discussion is here: How to create mailto: in gridview?

Categories : Asp Net

mailto not working with phonegap
You need to use the phonegap plugin EmailComposer . Mailto command won't work on all platforms. That's the reason why this plugin is mostly used. https://github.com/purplecabbage/phonegap-plugins/tree/master/iPhone/EmailComposer All the guidelines to use it can be found at it's readme.txt i used this plugin its work perfectly in my apps

Categories : Cordova

Referrer header not found error while calling http requests from node.js
You're not passing a Referer header to request.get and apparently the server at http://[fullpath] expects it (perhaps as a sort of misguided form of security). Try adding one: headers : { Cookie : "COOKIE=" + my_cookie, Origin: 'http://my_url', "X-Requested-With": 'XMLHttpRequest', Referer : 'http://' + fullpath },

Categories : Node Js

How to get the referrer, paid/natural and keywords for the current visitor in PHP with new Google Analytics?
You can get the referer from $_SERVER['HTTP_REFERER'] (and store in in your own cookie). ^ If your uses unencrypted search you can look if the referer is google - it will contain the search keywords in a get parameter named "q". If the visitor used encrypted search (for example when he/she is logged in to her Google account) you cannot get the keyword (not even GA itself displays search keywords in that case). You can maintain a list of search engine names and if the referer matches an entry in the list you'll know that this was an organic search. Among other things Google uses utm parameters to identify campaign sources, and since these are merely GET-Parameters you can read them in your custom script. For auto-tagged adwords campaigns you cannot get the keywords, but the glcid-PArame

Categories : PHP

Href and mailto links in KnockoutJS
Using the attr and text properties in the data-bind attribute like so: <script type="text/template" id="customerSearchDisplayTemplate"> <tr> <td class = "hiddenId"><span data-bind="text: customerSearchID"/></td> <td><span data-bind="text: fullName" /></td> <td> <span> <a data-bind="text: primaryEmail, attr: {href: 'mailto:'+primaryEmail()}" /> <span/> </td> <td> <span> <a data-bind="text: secondaryEmail, attr: {href: 'mailto:'+secondaryEmail()}" /> <span/> </td> <td><span da

Categories : Knockout Js

Echoing html link mailto
Dont know why Ckediter is doing that but you can remove it using jquery <a id="link1" href="denied:mailto:name@domain.com">name@domain.com</a> <script> $(document).ready(function (){ $("#link1").attr("href","mailto:name@domain.com"); }); </script>

Categories : Cakephp

mailto not working with android jellybean
Try doing it like this, works fine for me :) Intent i = new Intent(Intent.ACTION_SEND); i.setType("message/rfc822"); i.putExtra(Intent.EXTRA_EMAIL , new String[]{"EMAIL ADRESS"}); i.putExtra(Intent.EXTRA_SUBJECT, "SUBJECT"); i.putExtra(Intent.EXTRA_TEXT , "BODY"); try { startActivity(Intent.createChooser(i, "Send email...")); } catch (android.content.ActivityNotFoundException ex) { Toast.makeText(Start.this, "Sorry, there is no email client installed", Toast.LENGTH_SHORT).show(); } Cheers, Felix

Categories : Javascript

get line feeds in php mailto link
Add %0D%0A which is hex for new line: <option value="mailto:bob@bob.com?subject=test&body=Please write soon.%0D%0AThank you.">Email </option> That will do the trick. http://jsfiddle.net/hescano/ayCP7/ To add Carbon Copy and Blind Carbon copy use the following: <option value="mailto:bob@bob.com?subject=test&body=Please write soon.%0D%0AThank you&bcc=email@email.com&cc=email@email.com">Email </option>

Categories : PHP

objShell.Run MailTo populate vars
You need to use ampersand (VBScript's Concatenation Operator) to generate your mailto URI. objShell.Run("mailto:MyEmail@address.com&subject=" & strComputer & "&body=" & IPConfig.IPAddress(i))

Categories : Vbscript

How to pass current URL to mailto body
'&' is used in mailto to separate different parts like: &subject=some_subject&body=message_body So will be interpreted as an (invalid) parameter for the mailto (and omitted). So if you want to have '&' (and the rest of url) inside the body, it needs to be replaced with their % value. Using a function like urlencode() will do the job. <?php function CurrentPageURL() { ... return urlencode($pageURL); } ?>

Categories : PHP

How to fire mailto urls from action method
try this : window.location.href = "mailto:address@dmail.com"; with body window.location.href = "mailto:address@dmail.com?body=yourBody"; Event with jquery $('button').on('click', function(){ window.location.href = "mailto:address@dmail.com?body=yourBody"; });

Categories : Javascript

Organizing variables on mailto form submit
first of all i have to say email by just html or javascript will end up looking weird just use php instead it is also quiet easy: /first make the variables of all the things you need $naam = $_POST['vnaam']; $mail = $_POST['email']; $achternaam = $_POST['anaam']; $tel = $_POST['telefoon']; $message = $_POST['commentaar']; $Name = $naam; //senders name $email = $mail; //senders e-mail adress $recipient = "receivers email"; //recipient $mail_body = //add the variables and text here by using . u get the same as + in javascript ; //mail body $subject = "Contact formulier van: " . $naam . " " . $achternaam; //subject $header = "From: ". $Name . " <" . $email . "> "; //optional headerfi

Categories : Javascript

mailto: in URLs without a mail client installed
You can determine what executable/command handles the mailto: protocol with AssocQueryString("mailto") (or by looking in hkcrmailtoshellopencommand). If your lucky this will be empty for a machine with no association set.

Categories : C++

Calling a user e-mail to add to a mailto link PHP
As the Wordpress Codex says: Use get_the_author_meta() if you need to return (not display) the information. You're currently using: $email = ((the_author_meta( 'email' ))); Change it to: $email = get_the_author_meta('email'); //no need of the brackets here Also, I'd rewrite the echo statement as follows: echo "<a href='mailto: $email'> <img style='border:none;' src='$src'/> </a>"; Hope this helps!

Categories : PHP

Javascript mailto string loses 'encodeURI' encoding
The link is decoded when you click it - that's normal. Since you have an http link within a mailto link, it should be encoded twice. Email clients do their best to make things that look like links clickable. They typically decide where the link ends in a somewhat arbitrary and unpredictable manner. In email, the best way to keep a link contiguous is to enclose it in angle-brackets like this: <http://www.example.com/url with spaces> But this isn't foolproof. Email is fragile and you can't control the content well enough with a mailto link. It might be better to try to reduce the complexity of the url - perhaps by providing or utilizing a url-shortener service. Any url longer than 74 or so characters is likely to be mangled by some email clients.

Categories : Javascript

Google Script copy to clipboard and mailto [Questions]
Since Google Sheets is not an application running on your computer, its script capabilities are very different from VBA in Excel. No access to your PC's clipboard, for one. No triggering of a print dialog, for another. You can do those things in a browser while using Sheets, but not from a script. The most straight-forward approach given the capabilities of Google Apps Script, though, will be: Change your script button to call a function that will... Build email with the embedded schedule, and Send the message. There is no need to hide or unhide columns this way, as the embedded schedule can be built of only the interesting columns. sendEmail() You've asked to preserve formatting and range-values, so here's an approach that will do that. The sendMail() function operates on the activ

Categories : Google Apps Script

mailto function in AS3 not fully working on android tablet
Be aware that the URLRequest string must be a valid URL encoded string, so no spaces or special characters. Perform an initial test with no variables, so try something like: function openEmail(e:Event):void{ navigateToURL(new URLRequest("mailto:name@domain.com?subject=Test&body=Hello")); gotoAndPlay(1, "Thank you"); } If that works you know you're on the right track. If that does work you can encode your variables with encodeURIComponent(); Best practice: escape, or encodeURI / encodeURIComponent

Categories : Android



© Copyright 2017 w3hello.com Publishing Limited. All rights reserved.