小编Tom*_*ger的帖子

Html/php硬刷新

我正在努力刷新我的页面,因为我随机化了我的数据库的顺序,但是当我通过html按钮刷新页面时它不起作用,直到一段时间过去了.我认为这是由于网络浏览器的缓存.如果我通过f5刷新它也不起作用,但如果我使用shift + f5它可以工作.

<?php
if(isset($_GET["genre"])) {
$db = mysqli_connect("localhost","localhost","","test","3306");
$genre = $_GET["genre"];
$sql = "SELECT tittel, aar, id, genre, plot FROM gruppe3_film WHERE genre LIKE '%$genre%' ORDER BY RAND()";
$resultat = mysqli_query($db, $sql);

$rad = mysqli_fetch_assoc($resultat);
    $tittel = $rad['tittel'];
    $aar = $rad['aar'];
    $id = $rad['id'];
    $plot = $rad['plot'];
    echo "
   <h2>$tittel ($aar)</h2>
   <br><a href='javascript:location.reload();'><img src='../image/DBFilmCover/$id.jpg'></a>
   <h4>$plot</h4>
   <hr><button><a href='javascript:location.reload();'><div class='black'>New Random $genre Movie</div></a></button>";
?>
Run Code Online (Sandbox Code Playgroud)

如你所见,我目前正在使用<a href='javascript:location.reload();'>,但我也尝试过javascript:window.location.href=window.location.href内部href

html php page-refresh

1
推荐指数
1
解决办法
5524
查看次数

Azure Pipeline:使作业在同一池中的同一代理上运行

我有一个 YAML 脚本,如下所示:

jobs:
- job: UnixBuild
  pool: 
    name: BuildMachinesUnix
  steps:
  - bash: echo "Build Unix"

- job: WinBuild
  pool: 
    name: BuildMachinesWindows
  steps:
  - bash: echo "Build Windows"

- job: UnixRelease
  dependsOn:
    - UnixBuild
    - WinBuild
  condition: and(succeeded('UnixBuild'), succeeded('WinBuild'))
  pool: 
    name: BuildMachinesUnix
  steps:
  - bash: echo "Release on Unix"

- job: WinRelease
  dependsOn:
    - UnixBuild
    - WinBuild
  condition: and(succeeded('UnixBuild'), succeeded('WinBuild'))
  pool: 
    name: BuildMachinesWindows
  steps:
  - bash: echo "Release on Windows"

Run Code Online (Sandbox Code Playgroud)

每个池都有多个代理,我希望承担 UnixBuild 作业的代理也能处理 UnixRelease 作业,因为该版本的所有文件都在那里,这样我就不需要在发布步骤中重建它,并且WindowsBuild 也是如此

这样的事情可能吗?如果可能的话,怎么可能?

如果没有,对于如何仅在 Unix 和 …

yaml azure-pipelines azure-pipelines-yaml

1
推荐指数
1
解决办法
2791
查看次数