Is there a way I can display content based on a URL parameter being present, in Angular?
For example, myfile.php?id=123
<div ng-if="window.location.search.id != ''">
Show content
</div>
Inside of your controller/directive you can inject $location and use it to check for query params
angular
.module('locationExample', [])
.controller('ExampleController',
['$scope', '$location', function($scope, $location) {
$scope.search = $location.search();
}]);
<div ng-if="$scope.search.id != ''">
Show content
</div>
ui-router?