I am currently editing the code of my Symfony 1.4 Website using Sublime Text and pushing it to the web server with an FTP client.
However I have added a new module called 'about' and added the template and actions folders with the relevant files but when i try to go to mysite /about it just redirects me to another page.
I have the Routing.YML setup as follows
homepage:
url: /
param: { module: home, action: index }
about:
url: /about
param: { module: home, action: about }
stats:
url: /footballfans/stats
param: { module: footballfans, action: stats }
dailytips:
url: /dailytips/index
param: { module: dailytips, action: index }
footballnews:
url: /footballfeed.:sf_format
param: { module: footballfans, action: atom, sf_format: atom }
requirements:
sf_format: (?:atom)
default_index:
url: /:module
param: { action: index }
default:
url: /:module/:action/*
Is there any reason why these changes aren't being pushed to the site? Or do I have to edit a different file as well?
When I edit the template files these changes are being shown in the live site...
When I edit the VIEW.YML file to change the website SEO settings these also aren't being updated...
Related
I have a problem with the site configuration of news when there are two news plugins on one page (TYPO3 v9.5.20). There is a list view and a tag list as navigation for the tags ([screenshot1][1]). In the list view I am able to click on tags and only news with these tags are displayed. This works and the URLs fit. So everything is ok.
But if I activate the tag list plugin I get an error ([screenshot2][2]): The controller "News" is not allowed by plugin "Pi1". Please check for TYPO3\CMS\Extbase\Utility\ExtensionUtility::configurePlugin() in your ext_localconf.php.
The site configuration in config.yaml looks like this:
routeEnhancers:
News:
type: Extbase
limitToPages:
- 141
- 142
extension: News
plugin: Pi1
routes:
- routePath: 'page/{page}'
_controller: 'News::list'
_arguments:
page: '#widget_0/currentPage'
- routePath: '/{news-title}'
_controller: 'News::detail'
_arguments:
news-title: news
- routePath: '/{category-name}'
_controller: 'News::list'
_arguments:
category-name: overwriteDemand/categories
- routePath: '/{tag-name}'
_controller: 'News::list'
_arguments:
tag-name: overwriteDemand/tags
defaultController: 'News::list'
defaults:
page: '0'
aspects:
news-title:
type: PersistedAliasMapper
tableName: tx_news_domain_model_news
routeFieldName: path_segment
page:
type: StaticRangeMapper
start: '1'
end: '100'
category-name:
type: PersistedAliasMapper
tableName: sys_category
routeFieldName: slug
tag-name:
type: PersistedAliasMapper
tableName: tx_news_domain_model_tag
routeFieldName: slug
[1]: https://i.stack.imgur.com/LsFux.png
[2]: https://i.stack.imgur.com/H2IZn.png
I am trying to use the ensureSignedIn plugin on all routes except for a front 'home' page that has buttons to login to separate parts of the site.
Here's my route for 'home':
Router.route('/', function () {
this.render('home');
});
Here's the line for the plugin and exceptions:
Router.plugin('ensureSignedIn', {
except: ['home', 'atSignIn', 'atSignUp', 'atForgotPassword']
});
Both snippets are from my lib/routes.js file, if that makes a difference.
I've tried adding different route names in the except: portion, and they get correctly excepted, but I can't for the life of me get the 'home' route to not show "Must be logged in".
I've googled and read through gitHub issues and haven't seen anyone else with this problem, so it's probably something I'm doing wrong and not a bug with useraccounts or iron-router.
Set the name of the / route to root, then add that route name to the ensureSignedIn settings:
Router.route('/', {
name: 'root',
template: 'home',
action: function() {
this.render();
}
});
Router.plugin('ensureSignedIn', {
except: ['root', 'atSignIn', 'atSignUp', 'atForgotPassword', 'atResetPwd']
});
I am working on Symfony2 project in which a kind of general bundle, let say CoreBundle, is managing all the routes (in this form, first.domain/a-route, second.domain/a-route, third.domain/a-route,...) of the website. Now I have been creating FirstBundle, SecondBundle, ThirdBundle with the idea to "transfer" the management of routes of each subdomain (firt, second, third,...) to the related bundle.
Beginning with the transfer of routes from CoreBundle to FirstBundle by editing /app/config/routing.yml file from:
resource: "#ProjectFirstBundle/Resources/config/routing.yml"
prefix: /
host: "{subdomain}.{domain}"
defaults: { _controller: ProjectFirstBundle:Public:aroute }
domain: %project_domain%
requirements:
domain: "%project_domain%"
subdomain: 'first'
to:
project_first_aroute:
path: /a-route
host: "{subdomain}.{domain}"
defaults: { _controller: ProjectFirstBundle:Public:aroute, domain: "%project_domain%" }
requirements:
domain: "%project_domain%"
subdomain: 'first'
And of course I have created controller and view files using the same schema as CoreBundle (by making an adaptation -- inheritance for .twig files).
Now the problem is only parent route (that is CoreBunble /a-route route) is being read when running the URL first.domain/a-route.
Any suggestions?
I want to serve a static HTML file from MeteorJS's public folder (as is possible with Rails and Express). The reason I'm doing this is because I have one template for the dynamic "admin" part of my webapp and another for the sales-y "frontend" part of the app.
I don't want this file to be wrapped in a Meteor template as suggested in this answer as it will automatically bring in the minified CSS, etc... that the dynamic pages use.
Is there a way I can setup the public folder (and all its subfolders) so that it serves index.html? This way http://app.com/ will load public/index.html?
You could use the private folder instead and then use Assets.getText to load the contents of the file, then serve it with a server-side router from iron-router.
So off the top of my head the code would look something like this:
if (Meteor.isServer) {
Router.map(function() {
this.route('serverRoute', {
path: '/',
where: 'server',
action: function() {
var contents = Assets.getText('index.html');
this.response.end(contents);
}
});
});
}
this is what I put in bootstrap.js
Router.route('/', {
where: 'server'
}).get(function() {
var contents;
contents = Assets.getText('index.html');
return this.response.end(contents);
});
i changed my onlinesite,in online server,i created new module in schema.yml files.but the above error was comming.i remove catch file content.after that same error was comming.
Empty module and/or action after parsing the URL "/Planbook/planbook_new" (/)
#planbook
planbook:
url: /planbook
param: { module: planbook, action: index }
most_recent:
url: /planbook/most_recent
param: { module: planbook,action: mostrecent }
planbook_view:
url: /planbook/planbook_view
param: { module:planbook,action: view }
plan_new:
url: /planbook/plan_new
param: { module: planbook,action: new }
planbook_edit:
url: /planbook/planbook_edit
param: { module: planbook, action: edit }
highly_recommended:
url: /planbook/highly_recommended
param: { module: planbook,action: recommended }
mytrack:
url: /mytrack
param :{ module: planbook,action: mytrack }
plan_mate:
url: /planbook/plan_mate
param: { module: planbook, action: plan_mate }
#layer
layer:
url: /layer
param: { module: layer, action: index }
layer_new:
url: /layer/new
param: { module: layer, action: new }
layer_edit:
url: /layer/edit
param: { module: layer, action: edit }
layer_delete:
url: /layer/delete
param: { module: layer, action: delete }
layer_view:
url: /layer/view
param: { module: layer, action: view }
<a href="<?php echo url_for('/Planbook/planbook_new') ?>"
<a href="<?php echo url_for("#planbook_new") ?>"
hi plz help me.
Few things you must keep in mind
Make sure there are no cache files by using symfony cc or you can manually delete the contents of cache folder.
Make sure the database connection is configured properly in databases.yml as the login page may not require to be connected with database which is not the case regarding other pages.
Make sure that the rewrite_module has been enabled (I hope you are using wamp which makes it simple to enable it)
Make sure that cache and log folders have write permission (I don't think it will be an issue in a Windows machine)
You may also consider going through http://www.symfony-project.org/gentle-introduction/1_4/en/05-Configuring-Symfony
Thanks
Few things to perform:
check you error log
use your dev controller (something like frontend_dev.php) to see errors
and show us the error.
I don't think it's related to htaccess since you can display the login page.