Hi I am using drupal 6.x and ubercart 2.x. I trie dto create a product,but when it comes to add the file download feature I am getting some issue. I put a folder called downloads in the drupal folder and one file inside the download folder.then I gave the path as "drupal/downloads but it is telling that drupal/downloads is not a valid file or directory"
I tied the following file paths too
1.www.mysite.com/drupal/downloads/faq.ods
2.drupal/downloads/faq.ods
3.drupal/faq.ods(after putting faq.ods in the drupal folder.
But still I am getting the same message. Plesae some body help me
It is looking for a path rather than a URL. You should probably aim to find out from your hosting company what the absolute path for your webroot is (e.g. www.mysite.com may actually be on disk as /users/mysite.com/httpdocs) and put in that followed by /drupal/downloads
Related
I am getting a problem in deploying my app to the server. The problem is i have folders inside the webroot which points to the .css and .js files.
I was doing the basic cakephp function $this->Html->css('bootstrap') when my simple css files were in the css folder but now there are some other folders inside the webroot because of using the plugins for the frontend UI.
For this i have changed my url to like this $this->Html->css('/global/plugin/file')
Problem is on local it is working fine because of virtual host example.com but on live server i have domain like this 192.168.00.00/mysite so it go to the main directory to and link the ip 192.168.00.00 instead of going to 192.168.00.00/mysite.
Is there any good way to solve this and add the flexibility to the url so that my local and live will not be disturbed while i push my code through git?
Just removes '/' from $this->Html->css('/global/plugin/file') to below
<?php
$this->Html->css('global/plugin/file');
$this->Html->script('global/plugin/file'); //example loading file.js
?>
I already had an issue about this one including my JS and CSS inside a folder but when I removed '/' it solve my problem.
Confirm that their is a file.css inside plugin inside webroot\css\global\plugin\file.css windows path or LINUX path /webroot/css/global/plugin/file.css
I'm building a maven web application using Spring 3.0.5 MVC, AngularJS 1.5 and Boostrap 3.3.6.
All front-end resources are under webapp/resources/[js,css,fonts].
I've add <mvc:resources mapping="/resources/**" location="/resources/" /> to my spring configuration file.
My issue is that i'm not able to get glyphicons-halflings-regular.xxx files. I got a 404 not found error. (exemple with http://localhost:8080/my-app/resources/fonts/glyphicons-halflings-regular.woff)
I run my app with maven jetty plugin.
any hints?
Thanks in advance
Check that your font files are being copied to the target folder you expect them to be copied to. In your case, you should end up with the *.woff files under ~target/my-app/resources/fonts.
If the files are not in the correct/expected target location, check that you have correctly defined the resources element in your pom, and you're including the *.woff files.
Based on what you've said, I would expect your files to be placed into ~/target/my-app/[js,css,fonts] rather than ~/target/my-app/resources/[js,css,fonts]. If you see them there, then you can either remove the /resources portion of the links, or move the resources under /src/main/resources/resources.
If there are no *.woff files in the target folder at all, check the <resource> element of your pom and make sure you're including all the file types you want. If you need more control, take a look at the copy-resources goal of the maven-resources-plugin here: https://maven.apache.org/plugins/maven-resources-plugin/examples/copy-resources.html
Edit
I just noticed that you put your resources under /src/main/webapp/resources. Since this isn't the standard resource source folder, you can either move the resources into /src/main/resources or add the directory /src/main/webapp/resources to your resource list in the pom.
I am a beginar of m2e application development by using eclipse(kepler) and my server is jboss 7.1.1 final.I have two war files,one is for client and second is for server .I have an url pattern such as "myproject.com".Now my question is I want to access the data which is present in server war file even I made a changes i.e added the version number to war file for example "Server.war" to "Server0.0.1-SNAPSHOT.war" by using pom.xml file of my project.Would you please explain me what are the changes I need to do in my pom.xml file.
Thanks in advance,
Prasad
I am assuming that you want to keep the same web context despite the war file's name or whatever... In Jboss AS7 you can set the war's context root using the jboss-web.xml deployment descriptor. Just create the file into your_war/WEB-INF folder with this content,
<jboss-web>
<context-root>Server.war</context-root>
</jboss-web>
With maven you can package/install the war using a custom name and concat the version number if you want.
Set a custom name using <finalName> tag inside the build section, for example:
<finalName>ServerAnotherName-${project.version}</finalName>
Removing the tag, the default name will be ${project.artifactId}-${project.version}
I a complete noob at solr/java . I have solr 3.6.1 running on Tomcat(Windows) . I am able to get the solr admin page . I want to move ahead with DIH configuration . However the solarconfig.xml is confusing specially the paths for the class of request handlers. The request handler classes are specified as
"solr.SearchHandler" or as "org.apache.solr.handler.dataimport.DataImportHandler"
I cannot find either of these files either in my solr home directory or solr webapp (under the tomcat webapps folder) . I did find HTML files for these in my solr download (which is placed separately since I just copied the example/solr directory for solr_home and solr.war file for webapp) . Do I need to manually copy these files and if so where and how should my directory structure look like ?
solr.SearchHandler class is resolved by the Solr war file. For org.apache.solr.handler.dataimport.DataImportHandler class you should add the required jar file into the lib directory. Final solr directory should look like :
-solr
+conf
+data
-lib
+apache-solr-dataimporthandler-x.y.z.jar
+apache-solr-dataimporthandler-extras-x.y.z.jar
+apache-solr-x.y.z.war
+solr.xml
Also you should add other needed libraries inside the lib folder.
For DIH, you need to add the respective jar (apache-solr-dataimporthandler-x.jar) to the lib directory in webapps (Tomcat). Also copy the files in contrib/dataimporthandler/lib to this directory.
Every class files need for the DIH is inculded in the war file which comes with the web app folder. You can use these for your out of box functionalities. If you really want to work around the code for any customization then you can download the release with source code in the repositary.
I created a Play! app and deployed it under TomCat. This works well. The only problem is the management of a properties file, currently in the conf folder right next to application.conf. But as soons as the client replaces the war file the custom properties are overwritten with the default values, resulting in errors.
Now I want to introduce a seperate properties file placed inside the webapps folder. This way I will be sure my clients will not overwrite the file 'accidentally'.
So the structure would be:
TomCat webapps:
myPlayApp
PlayConfig <-- here I want to place the config file
So I would like to retrieve the properties file by something like:
getFile("../PlayConfig/app.properties");
This obvious does not work, but I do not know how to achieve this?
I thought retrieving it by tomcat http url but the portnumber my vary, so this would also not work, I guess...
UPDATE 2012-01-25:
Actually when using the following code:
Play.applicationPath.getPath();
I get the absolute path when running the project outside tomcat (so not inside war file!)
When I deploy the same project in a TomCat server I get the following output:
W:\tomcat-5.5\webapps\MyTestProject\WEB-INF\application.
From this point on I can indeed use a relative path.
I think that when deployed in a Servlet container, play uses the /WEB-INF/application as base directory.
Try changing the path relative to this folder.