php如何实现这样的需求,关于url的
例如 有几个栏目
PHP编程基础 PHP大牛 PHP大神
list/phpjichu.html list/phpdaniu.html list/phpdashen.html
对应链接
如何控制跳转链接通过字母显示
如何对应链接与程序调用的数据
超级菜鸟求帮助
回复讨论(解决方案)
求帮助
array('phpjichu'=>array('name'=>'PHP编程基础','url'=>'list/phpjichu.html'),'phpdaniu'=>array('name'=>'PHP大牛','url'=>'list/phpdaniu.html'),'phpdashen'=>array('name'=>'PHP大神 ','url'=>'list/phpdashen.html'))
这样写一个数组,应该明白了吧
表示看不懂你的描述
表示看不懂你的描述
大牛,或者这样说
我不想用urlwrite来做伪静态 伪静态是把那些.php 和参数什么的 变为友好的链接,例如.html 不带参数的那种链接
想直接就控制php程序的url规范
怎么弄 php新手 不知道楼上那位大牛是不是这样的 能否给个例子跑跑
array('phpjichu'=>array('name'=>'PHP编程基础','url'=>'list/phpjichu.html'),'phpdaniu'=>array('name'=>'PHP大牛','url'=>'list/phpdaniu.html'),'phpdashen'=>array('name'=>'PHP大神 ','url'=>'list/phpdashen.html'))
这样写一个数组,应该明白了吧
嗯 对应关系 明白
我不想用urlwrite来做伪静态 伪静态是把那些.php 和参数什么的 变为友好的链接,例如.html 不带参数的那种链接
想直接就控制php程序的url规范
能否给个例子跑跑
不用url rewrite 不能完美实现 list/phpxxxxx.html 这样的伪静态。
你硬是不用伪静态,又想实现这种效果,就只能生成相应的文件,让这个文件能用php解析,然后在文件内根据文件名 $_SERVER['SCRIPT_NAME'] 来获取你想要的参数。
array('phpjichu'=>array('name'=>'PHP编程基础','url'=>'list/phpjichu.html'),'phpdaniu'=>array('name'=>'PHP大牛','url'=>'list/phpdaniu.html'),'phpdashen'=>array('name'=>'PHP大神 ','url'=>'list/phpdashen.html'))
这样写一个数组,应该明白了吧
嗯 对应关系 明白
我不想用urlwrite来做伪静态 伪静态是把那些.php 和参数什么的 变为友好的链接,例如.html 不带参数的那种链接
想直接就控制php程序的url规范
能否给个例子跑跑
不想用伪静态,那你只有开启支持html运行php程序的,不过这样不安全
还有就是生成静态页的,不过这样就无法执行php代码的,不过可以借用JS做桥接来AJAX执行php

Hot AI Tools

Undresser.AI Undress
AI-powered app for creating realistic nude photos

AI Clothes Remover
Online AI tool for removing clothes from photos.

Undress AI Tool
Undress images for free

Clothoff.io
AI clothes remover

Video Face Swap
Swap faces in any video effortlessly with our completely free AI face swap tool!

Hot Article

Hot Tools

Notepad++7.3.1
Easy-to-use and free code editor

SublimeText3 Chinese version
Chinese version, very easy to use

Zend Studio 13.0.1
Powerful PHP integrated development environment

Dreamweaver CS6
Visual web development tools

SublimeText3 Mac version
God-level code editing software (SublimeText3)

Hot Topics



Alipay PHP...

JWT is an open standard based on JSON, used to securely transmit information between parties, mainly for identity authentication and information exchange. 1. JWT consists of three parts: Header, Payload and Signature. 2. The working principle of JWT includes three steps: generating JWT, verifying JWT and parsing Payload. 3. When using JWT for authentication in PHP, JWT can be generated and verified, and user role and permission information can be included in advanced usage. 4. Common errors include signature verification failure, token expiration, and payload oversized. Debugging skills include using debugging tools and logging. 5. Performance optimization and best practices include using appropriate signature algorithms, setting validity periods reasonably,

Article discusses late static binding (LSB) in PHP, introduced in PHP 5.3, allowing runtime resolution of static method calls for more flexible inheritance.Main issue: LSB vs. traditional polymorphism; LSB's practical applications and potential perfo

The application of SOLID principle in PHP development includes: 1. Single responsibility principle (SRP): Each class is responsible for only one function. 2. Open and close principle (OCP): Changes are achieved through extension rather than modification. 3. Lisch's Substitution Principle (LSP): Subclasses can replace base classes without affecting program accuracy. 4. Interface isolation principle (ISP): Use fine-grained interfaces to avoid dependencies and unused methods. 5. Dependency inversion principle (DIP): High and low-level modules rely on abstraction and are implemented through dependency injection.

How to automatically set the permissions of unixsocket after the system restarts. Every time the system restarts, we need to execute the following command to modify the permissions of unixsocket: sudo...

Session hijacking can be achieved through the following steps: 1. Obtain the session ID, 2. Use the session ID, 3. Keep the session active. The methods to prevent session hijacking in PHP include: 1. Use the session_regenerate_id() function to regenerate the session ID, 2. Store session data through the database, 3. Ensure that all session data is transmitted through HTTPS.

Static binding (static::) implements late static binding (LSB) in PHP, allowing calling classes to be referenced in static contexts rather than defining classes. 1) The parsing process is performed at runtime, 2) Look up the call class in the inheritance relationship, 3) It may bring performance overhead.

How to debug CLI mode in PHPStorm? When developing with PHPStorm, sometimes we need to debug PHP in command line interface (CLI) mode...
