{"action":"created","issue":{"url":"https://api.github.com/repos/Codeception/Codeception/issues/2499","labels_url":"https://api.github.com/repos/Codeception/Codeception/issues/2499/labels{/name}","comments_url":"https://api.github.com/repos/Codeception/Codeception/issues/2499/comments","events_url":"https://api.github.com/repos/Codeception/Codeception/issues/2499/events","html_url":"https://github.com/Codeception/Codeception/issues/2499","id":114027817,"number":2499,"title":"# hashtag or pound symbol is removed from webdriver url","user":{"login":"sbrauwers","id":14904671,"avatar_url":"https://avatars.githubusercontent.com/u/14904671?v=3","gravatar_id":"","url":"https://api.github.com/users/sbrauwers","html_url":"https://github.com/sbrauwers","followers_url":"https://api.github.com/users/sbrauwers/followers","following_url":"https://api.github.com/users/sbrauwers/following{/other_user}","gists_url":"https://api.github.com/users/sbrauwers/gists{/gist_id}","starred_url":"https://api.github.com/users/sbrauwers/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sbrauwers/subscriptions","organizations_url":"https://api.github.com/users/sbrauwers/orgs","repos_url":"https://api.github.com/users/sbrauwers/repos","events_url":"https://api.github.com/users/sbrauwers/events{/privacy}","received_events_url":"https://api.github.com/users/sbrauwers/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":4,"created_at":"2015-10-29T11:11:22Z","updated_at":"2015-10-29T11:33:53Z","closed_at":null,"body":"For my website I need the # symbol in the url, otherwhise it will not work.\r\nAcceptance.suite.yml\r\n```\r\n- WebDriver:\r\n    url: 'http://www.example.com/learner.html#'\r\n```\r\n\r\ntestCept.php\r\n```\r\n$I->amOnPage('/login');\r\n```\r\n\r\nBut when I run the test, it removes the # from the url.\r\nSo instead of \r\n```\r\n* I am on page \"/login\"\r\n\r\n  [GET] http://www.example.com/learner.html#/login\r\n```\r\nI see, which does not work for my application\r\n```\r\n* I am on page \"/login\"\r\n\r\n  [GET] http://www.example.com/learner.html/login\r\n```\r\n"},"comment":{"url":"https://api.github.com/repos/Codeception/Codeception/issues/comments/152153514","html_url":"https://github.com/Codeception/Codeception/issues/2499#issuecomment-152153514","issue_url":"https://api.github.com/repos/Codeception/Codeception/issues/2499","id":152153514,"user":{"login":"Naktibalda","id":395992,"avatar_url":"https://avatars.githubusercontent.com/u/395992?v=3","gravatar_id":"","url":"https://api.github.com/users/Naktibalda","html_url":"https://github.com/Naktibalda","followers_url":"https://api.github.com/users/Naktibalda/followers","following_url":"https://api.github.com/users/Naktibalda/following{/other_user}","gists_url":"https://api.github.com/users/Naktibalda/gists{/gist_id}","starred_url":"https://api.github.com/users/Naktibalda/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Naktibalda/subscriptions","organizations_url":"https://api.github.com/users/Naktibalda/orgs","repos_url":"https://api.github.com/users/Naktibalda/repos","events_url":"https://api.github.com/users/Naktibalda/events{/privacy}","received_events_url":"https://api.github.com/users/Naktibalda/received_events","type":"User","site_admin":false},"created_at":"2015-10-29T11:33:53Z","updated_at":"2015-10-29T11:33:53Z","body":"OK, WebDriver handles amOnPage in a completely different way than InnerBrowser: https://github.com/Codeception/Codeception/blob/deba99e48ee5799fc9305ada6a8a53256376594e/src/Codeception/Module/WebDriver.php#L490\r\n\r\nA simple fix would be to modify https://github.com/Codeception/Codeception/blob/c01a19f337e1afb06c926ee2cfc60d4e5eca20d4/src/Codeception/Util/Uri.php#L91\r\n\r\nto check if $path starts with '#' and don't add '/' between $url and $path if it does.\r\n\r\n@sbrauwers Would you like to beat me to it and make a pull request?"}}