struts


Struts The absolute uri: http://struts.apache.org/tags-bean cannot be resolved in either web.xml or the jar files deployed with this application

十年热恋 提交于 2020-02-16 08:49:34
问题 Using Servlet 3.0, Maven 4.0, JDK 8 with compliance 1.8. I don't know if the problem is due to eclipse not being able to build the project against the libraries correctly, or if it's tomcat. It may be a permission issue, despite the fact that i'm running both tomcat and eclipse as root, but who knows. At this point i'm starting to run out of ideas. Libs Imported The index.jsp <%@ page language="java" %> <%@ taglib uri="http://struts.apache.org/tags-bean" prefix="bean" %> <%@ taglib uri="http:

Remove .action extension in struts1 and to give user defined extension

倖福魔咒の 提交于 2020-02-06 15:04:32
问题 our application has developed in struts 1 , all action class has .action as extension, My action URL is Action URL: http://localhost:8089/Struts2/Login.action when i submit the action for this url , I want change the URL to "http://localhost:8089/Struts2/Login" or can i give any user defined name instead of .action 来源: https://stackoverflow.com/questions/58553020/remove-action-extension-in-struts1-and-to-give-user-defined-extension

Remove .action extension in struts1 and to give user defined extension

浪子不回头ぞ 提交于 2020-02-06 15:03:47
问题 our application has developed in struts 1 , all action class has .action as extension, My action URL is Action URL: http://localhost:8089/Struts2/Login.action when i submit the action for this url , I want change the URL to "http://localhost:8089/Struts2/Login" or can i give any user defined name instead of .action 来源: https://stackoverflow.com/questions/58553020/remove-action-extension-in-struts1-and-to-give-user-defined-extension

Variable in an attribute in Struts custom tag

a 夏天 提交于 2020-01-25 12:34:04
问题 I am trying to use a variable inside a custom Struts tag something like follows - for(String currentMacro : (List<String>)(request.getAttribute("individualMacros"))) { name = currentMacro.<some-operation> <html:mce name = "hmtl_<%= name %>" /> Something like this. But <%=name%> is not replaced with the variable value. It works when I am using the variable with a pure HTML tags. Is there any any way to accomplish this in this case? Thanks. 回答1: Use JSP EL (assuming JSP 2.0, and you put "name"

struts2 logs disabling from log4j.properties file

試著忘記壹切 提交于 2020-01-25 08:28:19
问题 I'm migrating from struts1 to struts2, i'm facing problems with logs which are continously logging with debug level Below are the logs which i took it from log file DEBUG 15287 [freemark] (): Key "errorposition" was not found on instance of java.util.LinkedHashMap. Introspection information for the class is: {getClass=public final native java.lang.Class java.lang.Object.getClass(), java.lang.Object@3c9557f1=freemarker.ext.beans.OverloadedMethods@174dae2d, clone=public java.lang.Object java

How to Convert Struts tags into Spring 4.0?

a 夏天 提交于 2020-01-16 19:31:07
问题 I have some custom code using Struts library which we are porting to Spring MVC I need to replace SkinTagUtils.findInScope("value1",pageContext) and SkinTagUtils.putToScope("key", key, "page", pageContext) lines into Spring or JSP.. 回答1: If you have pageContext object then you can use it to find a variable in the scopes. pageContext.findAttribute("value1"); or set it to the page scope pageContext.setAttribute("key", key); Note, there's also other convenient methods of JspContext to retrieve

how to dynamically download a file using struts 2 annotations (passing variable into annotation)

扶醉桌前 提交于 2020-01-16 19:07:02
问题 im new to struts 2 and im asking if there's a way to pass a variable argument into struts 2 annotation. here is what i already did but with no luck public class DownloadFileAction extends ModuleGenericClass{ private InputStream inputStream; private String fileName; @Action(value="/downloadFile",results={ @Result(name="success",type="stream",params = { "contentType", "application/octet-stream", "inputName","inputStream", "bufferSize","1024","contentDisposition", "filename=\"${fileName}\""}) })

how to dynamically download a file using struts 2 annotations (passing variable into annotation)

落花浮王杯 提交于 2020-01-16 19:05:51
问题 im new to struts 2 and im asking if there's a way to pass a variable argument into struts 2 annotation. here is what i already did but with no luck public class DownloadFileAction extends ModuleGenericClass{ private InputStream inputStream; private String fileName; @Action(value="/downloadFile",results={ @Result(name="success",type="stream",params = { "contentType", "application/octet-stream", "inputName","inputStream", "bufferSize","1024","contentDisposition", "filename=\"${fileName}\""}) })

Application at context path /HelloWorldStruts2 could not be started

吃可爱长大的小学妹 提交于 2020-01-16 05:30:07
问题 This is the my first Struts 2 application and I got this error "Application at context path `/HelloWorldStruts2` could not be started" when deploying on Tomcat. web.xml of my application: <?xml version="1.0" encoding="UTF-8"?> <web-app xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://java.sun.com/xml/ns/javaee" xmlns:web="http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd" xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_3_0.xsd

Spring security's integration with struts

梦想的初衷 提交于 2020-01-15 05:35:09
问题 i am trying to integrate spring security with struts1.2 (using LDAP) in a simple application i have applicationContext-security.xml <beans xmlns="http://www.springframework.org/schema/beans" xmlns:s="http://www.springframework.org/schema/security" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.0.xsd http://www.springframework.org/schema/security http://www

工具导航Map