PHP HTML,将类应用于html按钮而不是PHP链接文本 [英] PHP HTML, apply class to html button and not to PHP linked text

查看:67
本文介绍了PHP HTML,将类应用于html按钮而不是PHP链接文本的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有这个代码用于我的网站:



I have this code i use for my website:

<?php if ($slide1 != null ) : ?><li><img src="<?php echo $this->baseurl ?>

/<?
php echo htmlspecialchars($slide1); ?>" /><p class="caption">
<a href="/algemene-informatie"><?php echo ($slidedesc1); ?>Meer info</a></p></li>





代码不会像在这个例子。出于某种原因,我在这个编辑器中没有显示其他内容



现在整个事物显示为带有标题类的按钮。我只希望课程标题适用于Meer info而不是$ slidedesc1。我该怎么办?我是否更改了类的位置?



The code isn't seperated as in the example. For some reason I doesn't display otherwise in this editor

Right now the entire thing is displayed as a button with the class "caption". I only want class "caption" to be aplied on "Meer info" and not to "$slidedesc1". How would I do that? Do I change the position of class?

推荐答案

slide1!= null):?>< li>< img src =<?php echo
slide1 != null ) : ?><li><img src="<?php echo


this-> baseurl?>
this->baseurl ?>

/<?
php echo htmlspecialchars(


slide1);?> />< p class =caption>
< a href =/ algemene-informatie><?php echo(
slide1); ?>" /><p class="caption"> <a href="/algemene-informatie"><?php echo (


这篇关于PHP HTML,将类应用于html按钮而不是PHP链接文本的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆